View Categories

GA4 eCommerce Tracking

Google Analytics 4 (GA4) helps you understand how travelers move through your site. Older tools stop at page visits; GA4 tracks the actions people take, so you can follow someone from viewing a trip to completing a booking. The GA4 eCommerce Tracking add-on connects Google Analytics 4 to WP Travel Engine and automatically sends this activity, so you can see exactly where in the booking process people book and where they drop off.

Features #

  • Connect through an existing GA4 setup or a new one, using either a Measurement ID or a GTM Container.
  • Send trip views, checkouts, and completed bookings to GA4 without any manual work.
  • Import a ready-made GTM container file that already has all booking events configured.

Prerequisites #

  1. You have WP Travel Engine installed and activated on your WordPress site.
  2. You have a Google Analytics 4 property set up in your Google Analytics account.
  3. You have installed and activated the GA4 eCommerce Tracking add-on.

How to Install #

Verifying Installation #

To confirm the add-on is active:

  1. Go to your WordPress Dashboard.
  2. Navigate to WP Travel Engine > Settings > Extensions > GA4 eCommerce Tracking.
  3. Confirm that the GA4 Ecommerce Tracking settings page appears.

If the page doesn’t appear, deactivate and reactivate the add-on from the Plugins screen.

Connecting GA4 to Your Site #

This is a global setting, so it applies across your whole site rather than per trip. 

GA4 Connection #

Pick the option that matches your setup: 

  • Use Existing Connection – Choose this if GA4 is already connected to your site through another plugin, such as Site Kit by Google. The add-on works alongside it with no extra setup.
  • Set Up New Connection – Choose this if GA4 isn’t connected yet. This reveals Connection Type and Tracked Events below, where you add your GA4 details directly.

Connection Type #

Once Set Up New Connection is active, choose how you want to connect: Measurement ID or GTM Container.

Measurement ID

The more straightforward option. Select the Measurement ID tab, then:

  1. Open your Google Analytics account and go to Admin → Data Collection and modification → Data Streams → your stream.
  2. Copy the ID shown at the top right. It starts with G-.
  3. Paste it into the Measurement ID field.

Don’t Have a GA4 Property Yet? #

If you’ve never set up Google Analytics before, create a property first:

  1. Go to analytics.google.com and sign in with your Google account.
  2. Click Admin, then Create Property.
  3. Enter a property name, your time zone, and your currency, then click Create.
  4. Under Data Streams, choose Web, enter your website URL, and click Create Stream.

Your Measurement ID appears at the top of the stream details. Come back here and paste it into the Measurement ID field above.

GTM Container ID

Choose this if you already use Google Tag Manager to manage tracking on your site. Select the GTM Container tab, then:

  1. Open Google Tag Manager and copy the Container ID next to your container name. It starts with GTM-.
  2. Paste it into the GTM Container ID field.
  3. Download the ready-made container file from the notice below the field and import it into GTM. This file has the booking triggers already configured.

Don’t Have a GTM Container Yet? #

If Google Tag Manager is new to you, set up an account and container first:

  1. Go to tagmanager.google.com and sign in.
  2. Click Create Account, enter your business name, and continue.
  3. Under Container, enter your website domain, select Web, and click Create.

Once your container exists, copy its Container ID and come back to paste it into the GTM Container ID field above.

Tracked Events #

After you’ve set up your connection, WP Travel Engine shows the events it sends to GA4. All three are always active and can’t be turned off individually.

Event NameTrigger
view_itemFires the moment a traveler opens a trip detail page
begin_checkoutFires when a traveler clicks through from the booking window to the checkout page, after choosing dates, traveler count, and any add-ons
purchaseFires when a traveler’s payment goes through and the booking is confirmed. For deposits or installments, this fires once, after the first payment

Click Save Settings once your connection is set up.

Confirming Data Is Flowing #

Once you’ve saved your settings, check that events are actually reaching GA4 before you move on.

If you connected via Measurement ID:

  1. Open your site in a new browser tab and browse a trip page.
  2. In GA4, go to Reports → Realtime.
  3. You should see your session and events appear within a few seconds.

If you connected via GTM Container:

  1. In Google Tag Manager, click Preview.
  2. Enter your website URL and click Connect.
  3. Browse a trip page and start a test booking.
  4. In the Tag Assistant window, confirm the imported GA4 tags fire on the pages you visited.

What Gets Tracked #

The add-on tracks three moments in the booking journey, and everything happens in the background. Here’s what each one means and what you can learn from it in GA4.

Traveler views a trip: Track when a traveler opens a trip detail page. Use this to spot trips with a lot of views but few bookings. That gap usually points to something worth reviewing, such as pricing, dates, or trip content.

Traveler starts checkout: Track when a traveler clicks through from the booking window to the checkout page after choosing dates, traveler count, and any add-ons. If people reach this step but don’t complete it, check your checkout flow, pricing, or payment options.

Traveler completes a booking: Track when payment goes through, and the booking is confirmed. This is your conversion event and the one that feeds your revenue figures in GA4. The amount recorded is what the traveler actually paid, after any discount codes.

A few things worth knowing about when this fires:

Payment scenarioTracked?
Full paymentYes. Tracked once when the full amount is paid
Deposit or first installmentYes, but only after the first payment. Follow-up payments aren’t tracked again
Pay Later, bank transfer, or offline paymentsNo. Only online payments are tracked

Viewing Your Data in GA4 #

Once connected, your booking data appears in GA4 under Reports → Drive Sales → Ecommerce purchases

To see the full journey from trip view to purchase, use Explore → Funnel exploration in GA4 and add the tracked steps as stages.

FAQ #

Do I need both GA4 and Google Tag Manager? #

No. Choose one connection type based on what you already use. If you’re not sure, Measurement ID is the simpler option.

Can I track additional events beyond the three listed? #

Not through this add-on directly. If you need custom events, you’d manage those through your own GTM container setup separately.

I already use Site Kit by Google. Will this add-on conflict with it? #

No. Select Use Existing Connection and the add-on sends events through your current GA4 setup without creating a duplicate connection.

Why don’t I see any data in GA4 after connecting? #

GA4 can take 24 to 48 hours to show new data after you first connect. If it’s been longer than that, revisit Confirming Data Is Flowing to check whether events are reaching GA4 at all.

Does switching from Measurement ID to GTM Container keep my old data? #

Yes. Past events already sent to GA4 stay in your reports. Switching connection types only changes how future events are sent.

Will offline bookings, like Pay Later or bank transfers, show up in my revenue reports? #

No. Only bookings paid online are tracked as a purchase event, since GA4 can only record payments completed through your site.

#