"Let people pick a time" sounds like a one-day feature. We build WordPress themes at NodeThemes, and when we added appointment booking and a class schedule to our theme Avelyn (for coaches, beauty and yoga studios), the calendar was the easy part. Here is what actually took the time, in case you are building or choosing one.
Disclosure: we make Avelyn. The full, non-technical guide for business owners is on our blog: Online booking on WordPress for coaches and studios.
1. A free time is not just "not booked"
A start time is offered only when all of these are true:
- it lies inside the opening hours of that weekday (with an optional second range for a lunch break),
- the date is not in the closed-dates list,
- it is later than now + minimum notice and earlier than today + days ahead,
- the service length plus the break after it fits before the range ends,
- it does not overlap another booking, including that booking's break.
In code that is an interval check, not an equality check:
// $start / $end in Unix time; $buffer = break after, in seconds. function overlaps( $start, $end, $buffer, $booked ) { foreach ( $booked as $b ) { if ( $start < $b['end'] + $b['buffer'] && $b['start'] < $end + $buffer ) { return true; } } return false; } 2. Two people, one slot, same second
Two clients can click the last free time at the same moment. Re-checking availability just before saving is not enough. You need a short lock around "check + insert" so the second request sees the first booking. We use an option-based lock with a short expiry, which works on shared hosting without extra database tables.
3. Time zones
Everything is stored in UTC and shown in the site time zone from Settings → General → Timezone. Choose a city, not a UTC offset, so summer time is handled. The booking widget shows the time zone label next to the times; coaches with international clients get far fewer "is that my time or yours?" e-mails.
4. Calendar files and links
Every confirmation e-mail has:
| What | Why |
|---|---|
An .ics file (RFC 5545) | Opens in Apple Calendar, Outlook and Google Calendar |
| An "Add to Google Calendar" link | Most clients use Google Calendar on their phone |
| A "Manage booking" link with a secret token | Cancel online without an account |
The cancel link respects a limit (for example 24 hours before), and the client gets a reminder e-mail a set number of hours before the start.
5. Classes are a different problem
A class is a fixed weekly time with a capacity, so the questions change:
- How many spots are left right now?
- Has this e-mail address already reserved this exact class time?
- When the class is full, can people join a waitlist?
- When someone cancels, the first person on the waitlist is confirmed automatically and gets an e-mail.
We also keep a small "My bookings" list in the visitor's browser (localStorage), so people can see which classes they reserved on that device without creating an account.
6. The boring parts that matter
- Spam: a hidden honeypot field plus a rate limit per visitor on every public endpoint.
- E-mail delivery: many hosts do not deliver mail sent by WordPress. The docs tell users to install an SMTP plugin, and the first test booking proves it works.
- Privacy: bookings are registered with WordPress's personal data exporter and eraser, so a "delete my data" request covers them too.
- Payments: we deliberately do not charge at booking time. Packages, passes and gift cards are WooCommerce products. It keeps booking simple and lets each business choose its payment provider.
7. Settings people can actually find
Our first version used the WordPress Site Editor for page design. Business owners wanted one place for everything, so version 1.1 moved to a single settings panel: business details, colors and fonts, header and footer, and the sections, texts and photos of every page, next to the booking rules.
Checklist if you are choosing a booking tool
- Breaks between appointments and two ranges per day
- Minimum notice and "days ahead"
- Time zone shown on the booking page
-
.icsfile, Google Calendar link and an online cancel link - Waitlist for classes
- No double bookings under load
- Works with WordPress's privacy tools
The long version, written for coaches and studio owners rather than developers, is here: Online booking on WordPress for coaches and studios.



