I’m building a doctor appointment booking app in Bubble.io.
Patients can select their own time zone in account settings, and doctors have fixed working hours. I need the appointment booking flow to work correctly when patients and doctors are in different time zones.
Main requirement:
Available time slots should be displayed correctly based on the patient’s selected time zone
Appointments should be saved correctly so that both:
the patient sees the correct local time
the doctor sees the correct time in their own time zone
I’m not sure about the best practice in Bubble for:
Storing appointment date/time (UTC vs local time)
Converting available slots based on the patient’s selected time zone
Avoiding issues with different time zones and daylight saving time
What is the recommended approach for this in Bubble.io?
Pick a fixed timezone to store time in db (utc is best)
When you know for a fact that date in db is fixed at a timezone you can display it anyway you like. Selecting utc as fixed in db makes this easy as it is the standard way of doing things