Widgets let visitors browse dates and book your trips right from your own website.
The widgets you can add
Button — a "Book now" button.
Upcoming departures — a list of a trip's next dates.
Calendar — an availability calendar that shows every date you have departures scheduled for, however far ahead. If the trip also takes on-request bookings, visitors get a toggle to switch to "pick any date" mode and send a request instead; switching back and forth keeps your place in each view.
Product list — a grid or list of all your published trips. If you've grouped trips into folders, this widget leads with those folders as cover cards by default; visitors tap one to browse its trips. Turn this off for a specific widget with the Skip folder navigation option.
Each can open the booking flow in a fullscreen pop-up (the default), a smaller pop-up, or a new tab.
If you've set a different price for a specific date (see Setting your availability and departures), the Upcoming departures and Calendar widgets show that date's actual price, with its label as a badge and the regular price crossed out beside it (if you've turned that on). The Button and Product list widgets always show your trip's regular starting price, since they aren't tied to one date.
Folders
If you've grouped your trips into folders, the Product List widget shows those folders as cover cards by default, with any ungrouped trips listed below. To skip folders and always show a flat grid of every published trip instead, turn on Skip folder navigation in the widget's settings (or add data-samba-show-folders="false" if you're hand-editing the snippet).
How to add one
In Settings → Website Widgets, pick a widget and adjust its options — there's a live preview as you go. You'll get a two-part snippet:
Once per page — paste the small script into your site's
<head>.Where you want the widget — drop in the widget's snippet wherever it should appear.
The script automatically powers every widget on the page, so you only need it once no matter how many widgets you add.
Using the WordPress plugin
If your site runs on WordPress, install the Samba WordPress plugin instead of hand-pasting code. Under Settings → Website Widgets → WordPress, copy your workspace's connection key and paste it into the plugin — it then lists your published trips and builds each widget for you, no HTML required.
If you ever regenerate that key, your WordPress site stops pulling widgets until you paste the new key into the plugin — so only regenerate it if you suspect the old one was exposed.
Auto-apply discount codes
Each widget has an optional auto-apply discount code setting. Set one, and visitors who come through that widget get it applied automatically at checkout — no code for them to type in. This works with codes that apply workspace-wide and with codes scoped to a specific trip.
Checkout always double-checks the code in full before using it — including any restriction to specific departure dates — so a code that turns out not to apply (wrong dates, expired since the page loaded) is simply skipped rather than shown to the visitor as an error.
In Settings → Website Widgets, you pick the code from a list of the ones that are currently active and apply to that widget — workspace-wide codes, plus any scoped to the trip the widget is pinned to. Change which trip the widget is pinned to and a trip-specific code is cleared for you, since it no longer applies; a workspace-wide code stays selected.
In the WordPress plugin, you type the code in instead (up to 64 characters — capitalization and stray spaces don't matter). Because it's typed rather than picked, two things are on you: there's no list of which codes are currently valid, and nothing clears the code if you later point the widget at a different trip. A trip-specific code left on a widget for another trip looks fine in the editor but gets skipped at checkout, and the visitor isn't told. Copy the code you want from Settings → Discount codes, and revisit it when you change the widget's trip.
Choosing a language
Each widget also has a Language setting, whether you build it in Settings → Website Widgets or in the WordPress plugin. Leave it on Auto (the default) and the widget matches the language of the page it's embedded on, or the visitor's own browser language if the page doesn't specify one — the right choice if your site has one page per language. Or pin it to one of your workspace's enabled languages instead, so it always shows in that language regardless of the visitor's settings — see Workspace settings and branding for how to enable languages.
If you later turn off a language a widget is pinned to, that widget switches back to Auto automatically rather than continuing to show a language you no longer offer.
Good to know
Visitors don't need an account to use a widget.
Only published trips show up in widgets.
