Five days is short enough that every hotel change costs you a half day, so the plan below uses only two bases and no more than one long drive between them. It suits a first visit that wants temples and rice country as well as a beach and a sunset. If you have a week or more, the main Bali itinerary guide covers 7, 10 and 14 days; this page is the detailed answer for 5.
The shape is simple. Days 1 to 3 are in Ubud, inland. Days 4 and 5 are on the south coast, around Seminyak and Uluwatu. Nusa Penida is offered as a swap for one day, and a one-base version follows for anyone who does not want to move hotel at all.
Why two bases, not five
Bali looks small on a map, but roads are slow and a day of driving between hotels is a day lost. Our own routing on OpenStreetMap roads gives these distances: the airport is 32.8 km from Central Ubud and 11.5 km from Seminyak (Petitenget). Central Ubud to Seminyak is also 32.8 km.
That is the reason for the order. If you start on the coast and finish in Ubud, the long transfer falls on departure day, when you have a flight to catch. Starting in Ubud puts the long drive on day 1, when you have no deadline, and the last morning is a short run of 11.5 km. The region guides put the drive from the airport to Ubud at about 1.5 hours and the run to Seminyak at 30 to 45 minutes, and the afternoon peak is slower in both cases.
Visit between May and October, the dry season on this site, if you can. Seas are calmer, which matters most if you choose the Nusa Penida swap. See the airport guide for arrival and departure steps.
Day 1: arrive and walk Ubud
Land, clear immigration and take a pre-booked car to Ubud. Allow about 1.5 hours for the 32.8 km. Check in, then keep the rest of the day light. Walk to Ubud Palace, free by day, and then to the lotus pond at Pura Taman Saraswati, a short walk away. The palace stages a dance in the courtyard every night, so you can end the day there.

If you land in the morning, add the Campuhan Ridge Walk in the late afternoon. It is a 2 km paved path and takes 1 to 2 hours return, though the page recommends dawn for the cooler air, so treat an afternoon visit as the second best option.
Day 2: Ubud on foot
Start at the Campuhan Ridge Walk at dawn if you skipped it on day 1; it is free and open around the clock. Be at the Sacred Monkey Forest for the 9am opening, before the tour groups, and allow 1 to 1.5 hours. No food or plastic bags go inside, and a bite means a trip to the on-site clinic.
The afternoon is for the things you can only do in Ubud: a cooking class, a craft stop or a long lunch overlooking a valley. Leave the evening free. Nothing on day 2 needs a car, which makes it a good day to recover from the flight.
Day 3: a day out from Ubud
This is the day you spend with a driver. The standard loop is the Tegallalang rice terraces, 11.6 km from Central Ubud, followed by Tirta Empul, the spring temple at Tampaksiring. Go to the terraces before 9am, when the cafes open and the crowds arrive. Tirta Empul is best early on a weekday. Keep your driver waiting there, since the page warns that ride-hailing pickups are hard to find for the return.

If you prefer water to temples, finish at Tegenungan Waterfall on the way back towards the south, and paddle only at the edges. A private driver for the day is the simplest way to string these together; see the private driver guide for how booking works, or browse Ubud tours if you would rather join a group.
Day 4: move to the coast, Uluwatu at sunset
Take the morning to drive from Ubud to the south coast. The distance to Seminyak is 32.8 km, and the afternoon traffic through the south is the slowest of the day, so leave after breakfast. Drop your bags and have lunch.
In the late afternoon, go on to the Bukit peninsula. From Seminyak, Uluwatu Temple is 27.6 km away. If you are staying near Uluwatu instead, Padang Padang Beach is a 15-minute scooter ride from the temple, with about 120 steps down; its page suggests the morning for space, so keep it for day 5 rather than squeezing it in before sunset.
The temple page says the Kecak dance starts at 6pm each evening, so arrive earlier to walk the cliff path in the light. Keep glasses, hats and phones zipped away, because the macaques take them. Book the return ride before the show starts, or expect a long wait afterwards.

Day 5: a beach morning and departure
Use the last day for one beach and an unhurried lunch. Bingin Beach and Suluban Beach are the two other beaches on the Bukit; Suluban is best at low tide and Bingin has no toilets yet, so check the tide first. Or stay near Seminyak and walk the sand. From Seminyak the airport is 11.5 km, so an evening flight works well, but leave time for the traffic and arrive at the terminal 3 hours before an international departure, as the airport guide recommends.
Where you sleep on days 4 and 5 is your choice. Seminyak is closer to the airport and has more restaurants; Uluwatu is quieter and nearer the cliffs. Compare them on the Seminyak and Uluwatu pages, or see the wider where to stay in Bali overview. For a guided afternoon on the peninsula, check Uluwatu tours.
Swap for Nusa Penida
You can replace day 3 with a day on Nusa Penida, but it is a swap, not an addition, and it costs more time than it looks.
The boat leaves from Sanur, which is 23.8 km from Central Ubud, so you start with a road transfer before you reach the harbour. The region guide gives the fast boat as 30 to 45 minutes each way and says crossings are frequent in the dry season but cancelled when the sea is rough; the Kelingking Beach page gives 40 to 50 minutes from Sanur to Toya Pakeh, then 45 to 60 minutes by road. On the island, the roads are rough and steep. Broken Beach is 20 to 30 minutes on from Kelingking.

The west coast is the practical choice for one day: Kelingking, Broken Beach and Angel’s Billabong are close together. Diamond Beach is on the east coast, about an hour by road, so do not try both coasts in one day. Swimming is banned at Kelingking, Angel’s Billabong and Diamond Beach, and at Kelingking you should stay on the marked path down the cliff. Book through Nusa Penida tours or use the fast boat guide to book the crossing yourself, then arrange a driver on the island.
The one-base version
If you would rather not move hotel, stay in Seminyak for all 5 nights. You are 11.5 km from the airport on both ends, and every other stop becomes a day trip. Ubud is 32.8 km each way, so make it a full day: palace and market in the morning, then Tegallalang and Tirta Empul with a driver. Tanah Lot is 12.4 km from Canggu (Batu Bolong) and suits a sunset visit, and Uluwatu is 27.6 km away for the sunset Kecak. See Canggu tours for options near the coast.
The trade is plain. You give up evenings in Ubud and the early start at the terraces, and spend more of each day in the car. In return, you unpack once and never lose a morning to a check-out.