Skip to content
weLabsweLabsStorefront Playbook
Live demoQuickstart

Store admin

Scripts and promo popup

Add Google Tag Manager, Meta Pixel, consent tools, verification tags and chat widgets to the storefront, and set up the first-order promo popup.

Because the storefront is a separate site, a WordPress plugin that adds tracking or chat code cannot reach it. The Header/Footer Scripts tab is where you paste that code instead, and the storefront places it on its pages. On the same settings screen, the Promo popup tab sets up the first-order offer shown to new visitors.

StoreFrontSettingsHeader/Footer Scripts
  • You need the WordPress unfiltered_html permission. Administrators on a normal single site have it. On a multisite network, or when DISALLOW_UNFILTERED_HTML is set in wp-config.php, the tab is read-only with an error banner, and saves are ignored.
  • Have each snippet ready, exactly as the service gives it to you.
  • EU stores: choose a consent tool (such as Cookiebot or CookieYes) first. The storefront does not hold back tracking by itself, so the consent tool must load before your tags.
  1. Go to StoreFront → Settings and click Header/Footer Scripts (the last entry in the rail).
  2. Paste the snippet into the right box (see the table below). Paste it exactly as the service gives it.
  3. Make sure the box’s switch is on.
  4. Click Save Changes.
  5. Wait up to 5 minutes, then check on the storefront (for example with Google Tag Manager’s Preview mode or the Meta Pixel Helper browser extension).
Setting What it does Default
Head (“Load the Head scripts”) Loads first, before every other snippet. For your consent tool, tag manager, pixel and site-verification <meta> tags. <meta> and <link> tags go into the page head; scripts run first; anything else (such as GTM’s <iframe> fallback) is placed at the start of the page body. On, empty
Body start Placed right after the page body opens. For the <noscript> part of Google Tag Manager or Meta Pixel. On, empty
Footer Placed just before the page body closes. For live-chat widgets (Tawk.to, Crisp, Tidio and similar) and anything that can load last. On, empty

Each box holds up to 65,536 characters, with a live counter. The code is stored exactly as typed. Turning a box off keeps its code but stops it loading, which is handy for testing.

Service What to paste, and where
Consent tool (Cookiebot, CookieYes…) Its script into Head, so it loads before any tracking.
Google Tag Manager GTM gives you two snippets. The <script> one goes into Head; the <noscript> one goes into Body start.
Meta Pixel The pixel <script> into Head; its <noscript> image tag into Body start.
Google Search Console or Meta domain verification The <meta> tag (for example google-site-verification) into Head.
Live chat The widget script into Footer.

A verification tag looks like this, with your own code in place of the dots:

<meta name="google-site-verification" content="..." />

The storefront changes pages without a full reload. So that analytics still count every page, it sends a page view automatically on each move: a page_view event to Google Tag Manager’s dataLayer, and a Meta Pixel PageView.

  • Payment pages. The storefront leaves your scripts off the checkout and the order confirmation page, so no third-party code can read or cover the card fields. The notice at the top of the tab says the scripts run on checkout too; in fact the storefront skips them there. Account pages do run them.
  • Staging, preview and local copies of the storefront, when the developer sets STOREFRONT_CUSTOM_SCRIPTS=off in their configuration. Ask for this on any test copy that points at your live WordPress, so test visits never mix into your real analytics and ad data.
  • Only paste code from services you trust: these scripts run on almost every storefront page.
  • Changes can take up to 5 minutes to reach the storefront.
  • These scripts are never offered to AI assistants connected to the store; only a person in wp-admin can change them.
StoreFrontSettingsPromo popup

A first-order offer popup, with a photo and an email box, shown to signed-out visitors shortly after they arrive on any page. It is off by default.

  1. Go to StoreFront → Settings and click Promo popup.
  2. Switch on the Promo popup card.
  3. Type your own Title, Subtitle, Button label and Email field placeholder, or leave them blank to use the storefront’s built-in text.
  4. Click Add image to choose a photo, or leave it empty to use the storefront’s own photo.
  5. Click Save Changes.
Setting What it does Default
Promo popup (card toggle) Shows or hides the popup. Off
Title The popup heading. Blank (“Sign up to get 10% OFF your first order”)
Subtitle The line under the heading. Blank (“Join the list for new arrivals, offers and a little care advice.”)
Button label The button text. Blank (“Get 10% OFF”)
Email field placeholder The hint text inside the email box. Blank (“Enter your email”)
Image The photo beside the text, from the Media Library. Use Replace or Remove to change it. None (the storefront’s own photo)

The text in brackets is the storefront’s built-in copy, translated for each language, used while a field is blank.

How the popup behaves (these are fixed, not settings):

  • It appears 4 seconds after a visitor lands on any page.
  • Closing it hides it for 24 hours in that browser.
  • It never shows to signed-in shoppers.
  • It also shows your social icons from the Social Links tab.
  • The storefront’s deployment can switch it off entirely (NEXT_PUBLIC_PROMO_MODAL=0), whatever this toggle says.
Symptom Likely cause Fix
The Scripts tab is read-only with a red banner Your account lacks unfiltered_html (multisite, or DISALLOW_UNFILTERED_HTML). Ask a super admin, or your developer, to make the change.
A tag doesn’t fire on checkout Scripts are skipped on payment pages by design. Track purchases from your payment provider or WooCommerce instead.
Page views are counted twice A GTM History Change trigger is also set up. Remove that trigger.
Scripts don’t run on the staging site STOREFRONT_CUSTOM_SCRIPTS=off is set there. Expected; this keeps test visits out of live analytics.
The promo popup never appears It’s off, you’re signed in, you closed it in the last 24 hours, or the deployment disabled it. Switch it on, test in a private window while signed out, and ask your developer about NEXT_PUBLIC_PROMO_MODAL.
Storefront Playbook · Built by weLabsFeaturesFAQTalk to us