A tip for trip planning in equatorial places on the other side of the world is check the best time of year to travel. April and May are listed as two of the best shoulder season months for a trip to Bali when weather is good and hotel prices are lower.
Expedia has $494 China Southern Airlines round trip tickets for San Francisco to Denpasar, Bali DPS for travel departures in April and May 2018.
Most itineraries I checked require an overnight or all day 12+ hours layover in China at either Guangzhou CAN or Wuhan WUH on either the outbound or return flights. That seems like a bonus excursion opportunity to me.
Expedia ticket for China Southern Airlines flights
San Francisco SFO – Wuhan WUH – Guangzhou CAN – Bali Denpasar DPS – Guangzhou CAN – Wuhan WUH – SFO