Widget guide

Add booking to the website you already have

Your schedule, prices and sign-up, live on your own site in three steps. Members book, log in and pay inside the widget.

On WordPress? Use the plugin

The free Class Booking plugin adds the widgets as a block or a shortcode and loads the script for you. Paste your API key and studio address under Settings → Class Booking and click “Connect and check”.

Get the WordPress plugin

Set up in three steps

  1. 1

    Switch on widgets and create an API key

    In your Class Booking admin, switch on “Widgets for your website” under Settings → Advanced features → Website & content. Then open Widgets and click “Create API key”. Enter your website’s address under “Allowed domains (required)”, one per line. The full key is shown only once, so copy it straight away.

  2. 2

    Copy the setup code

    Right after you create the key, click “Copy setup”. The code already contains your key and your studio address. Paste it into your site wherever you can add HTML: an embed or code block in Wix, Squarespace or Webflow, or your page template.

  3. 3

    Place the widgets where you want them

    The script line only needs to be on the page once. Each widget is a tag you can put anywhere on the page, and you can use as many as you like.

The code looks like this

<script src="https://widgets.holdstyring.dk/v1/holdstyring-widgets.min.js" async></script>

<holdstyring-schedule api-key="YOUR_API_KEY" base-url="https://your-studio.class-booking.com"></holdstyring-schedule>
<holdstyring-pricing api-key="YOUR_API_KEY" base-url="https://your-studio.class-booking.com"></holdstyring-pricing>

Replace the key and the address with your own, or use “Copy setup” in your admin, which fills them in for you.

Popular widgets

All widgets, with the options for each, are listed on the Widgets page in your admin.

  • <holdstyring-schedule>

    Schedule with booking

  • <holdstyring-login>

    Log in and create an account

  • <holdstyring-bookings>

    The member’s upcoming bookings, with cancellation

  • <holdstyring-membership>

    Punch cards, membership and past purchases

  • <holdstyring-pricing>

    Price plans with purchase in the widget

  • <holdstyring-class-types>

    Class types with a booking button

  • <holdstyring-instructors>

    Instructor overview

  • <holdstyring-gift-cards>

    Gift cards with purchase in the widget

If a widget does not show

  • Check that your site’s exact address is in the key’s allowed domains. https://studio.com and https://www.studio.com are two separate entries.
  • Check that widgets are switched on under Website & content. When they are off, every request is refused, even with a valid key.
  • Make sure the script line is on the page. Some page builders strip scripts from text blocks, so use an embed or code block instead.

Questions about your setup?

Our support team helps you get the widgets onto your site.

Widget guide: add booking to your website | Class Booking