Skip to main content

[Booking Engine] Integrating with Google Tag Manager (GTM)

J
Written by Joelly See Toh

What Is Google Tag Manager (GTM)?

Google Tag Manager (GTM) is a tool that allows you to centrally manage various tracking tags installed on a website.

By configuring a GTM ID in the AirHost Booking Engine, you can set up various tracking tags through GTM.

For example, GTM can be used for tracking:

  • Google Analytics 4 (GA4) website visits and bookings

  • Conversion tracking for Meta ads (Instagram/Facebook ads)

  • Advertising performance measurement for Google Ads and other advertising platforms

Note:

We do not provide support for creating or operating Google Analytics or Google Tag Manager accounts.
Please refer to Google’s official help pages for guidance.


What You Can Do with GTM

By using GTM, you can send user behavior data from the Booking Engine to external analytics and advertising tools.

  • Access and Booking Analysis with GA4

    By integrating with GA4, you can track visits to the Booking Engine.

    AirHost automatically sends only the page_view event to GA4.

    AirHost does not automatically send a purchase event when a booking is completed. To track booking completions, you can configure GTM to use visits to the order details page as a trigger and track them as booking completions.
    ​[Booking Engine] Integrating with Google Analytics 4

  • Conversion Tracking for Meta Ads

    By setting up the Meta Pixel through GTM, you can track bookings made through Meta ads, such as Instagram and Facebook ads, as conversions in Meta Ads Manager.


Settings Required Before Use

Please make sure that the following settings have been completed before use.

  1. AirHost Booking Engine setup is completed.

  2. A Google Analytics 4 account has been created and connected to the AirHost Booking Engine.
    Help page: available here

  3. A Google Tag Manager account and container have been created.
    Help page: available here
    You can create a Google Tag Manager account from this page.

  4. A tag has been configured in Google Tag Manager for Google Analytics 4.
    Help page: available here


GTM Setup Procedure

1. Create a GTM account

From the GTM admin screen, select “Account” and click “Create Account.”

2. Configure the container

Set the container name. Please enter the domain name as the container name.

Review the Terms of Service. If you agree, check the checkbox at the bottom left, then click “Yes” at the top right.

3. Verify the assigned GTM ID.

A GTM ID will be assigned (e.g., GTM-XXXXXX)...①

An HTML code snippet...② will also be displayed, but in the AirHost Booking Engine, configuration can be completed by entering only the GTM ID, so this code is not required.

4. Register your GTM ID on the booking engine management screen.

From the AirHost Booking Engine admin panel, navigate to “Listing Management” → “Website.”

Enter the previously obtained GTM ID (①) into the “Google Tag Manager ID” field and click Save.

5. Set tags on the GTM side.

For tag configuration in Google Tag Manager and Google Analytics 4 settings, please refer to this help page.

For instructions on setting up tags in GTM and Google Analytics 4, please refer to the following page.


Tracking Bookings from Meta Ads (Instagram/Facebook)

By setting up GTM on the AirHost Booking Engine and installing Meta Pixel through GTM, you can track visits to the order details page as conversions in Meta Ads.

Follow these steps:

  1. Register your GTM ID in the AirHost Booking Engine.

  2. Set up the Meta Pixel base code in GTM.

  3. Configure the Meta "Purchase" event in GTM, using visits to the order details page as the trigger.

  4. Verify that the event fires correctly using GTM Preview Mode and the Test Events feature in Meta Events Manager.

Note: AirHost does not automatically send a booking-completion event. You must configure the event in GTM using visits to the order details page as the trigger.

Available Information

The order details page URL includes a hotel parameter that identifies the property. This parameter is available only for guest bookings.

You can configure GTM to retrieve this parameter and use it to identify the property in your tracking.

However, AirHost does not provide the following information:

  • Booking/transaction ID (transaction_id)

  • Booking amount (value)

  • Currency (currency)

  • Product information, such as property or room type (items)

Therefore, while you can track visits to the order details page as conversions, you cannot track conversion values or ROAS based on booking amounts, or deduplicate conversions using booking IDs.

Note: GTM and Meta Pixel tags and triggers must be configured by the User.


Cookie Consent Management

The AirHost Booking Engine currently does not support Cookie consent management features.

The following features are not supported:

  • Displaying a Cookie consent banner

  • Blocking the loading of tracking tags, such as GA4, or preventing tracking until the User gives consent

  • Stopping tracking after consent is withdrawn

  • Providing APIs or hooks for integration with external Consent Management Platforms (CMPs)

Additionally, Cookie consent preferences collected on your website cannot be transferred to the Booking Engine when they are hosted on different domains.

Therefore, even when using GTM, AirHost does not provide a built-in feature to control tags based on Cookie consent status.

For information on configuring Google Consent Mode and related Google features, please refer to Google's official documentation.


Frequently Asked Questions (FAQ)

Q. Can AirHost configure Meta Pixel or Purchase events for us?

A. No. You must configure these settings in GTM.

You are responsible for configuring the Meta Pixel base tag, Purchase event, and other related settings in GTM.

Please refer to Google's official documentation or consult your advertising agency for assistance with GTM configuration.

Please note that AirHost does not automatically send booking-completion events. You must configure the event yourself in GTM, using visits to the order details page as the trigger.

Q. Can I also retrieve the booking amount when tracking conversions from Meta ads?

A. No. AirHost’s current standard integration does not provide the booking amount (value).

Therefore, while you can track the number of completed bookings, conversion value and ROAS based on booking amounts cannot be measured.

Did this answer your question?