Analytics & Pixels (liteshop-analytics-pixels) adds Google Analytics 4 and/or a Meta (Facebook) Pixel to your LiteShoper storefront, with ecommerce events for product views, add to cart, checkout, and purchase.

On this page: Overview · Prerequisites · Install · Create GA4 · Create Meta Pixel · Paste IDs · Ecommerce events · Verify · Ads tips · Checklist · Troubleshooting

1. Overview

  • Loads GA4 (gtag.js) and/or Meta Pixel (fbevents.js) on the storefront only
  • Automatic PageView / base page tracking
  • Ecommerce: view_item, add_to_cart, begin_checkout, purchase (GA4 + Meta equivalents)
  • Toggle each event on/off in Settings
  • Purchase is deduped per order number per browser session (thank-you page reloads won’t double-count)

Plugin page: liteshoper.com/plugins/liteshop-analytics-pixels (if published) · In-store: Integrations → Analytics & Pixels

2. Prerequisites

  • Plugin activated under Admin → Plugins
  • Storefront on HTTPS (recommended for accurate browser tracking)
  • Optional: a GA4 property and/or Meta Business Pixel (you can use either or both)
  • Optional: cookie-consent banner if required in your region (this plugin does not include one)

3. Install the plugin

  1. Install / activate liteshop-analytics-pixels from the marketplace or Plugins
  2. Open Integrations → Analytics & Pixels → Setup Guide (or Settings)

4. Create Google Analytics 4 (Measurement ID)

  1. Open https://analytics.google.com/ and sign in
  2. Create an account / property if you don’t have one
  3. Admin → Data streamsWeb
  4. Create or open your web stream (website URL = your storefront domain)
  5. Copy the Measurement ID — format G-XXXXXXXXXX

Help: Set up a GA4 web stream · Verify with Google Tag Assistant or GA4 DebugView

5. Create a Meta (Facebook) Pixel

  1. Open Meta Events Manager
  2. Connect a data source → WebMeta Pixel
  3. Name the pixel and enter your storefront URL
  4. Copy the numeric Pixel ID (digits only)

Help: Create and install a Meta Pixel · Verify with Meta Pixel Helper (Chrome) or Events Manager → Test Events

6. Paste IDs in LiteShoper

  1. Go to Analytics & Pixels → Settings
  2. Check Enable Analytics & Pixels on the storefront
  3. Paste GA4 Measurement ID (G-…) and/or Meta Pixel ID
  4. Leave ecommerce event toggles on (recommended) or turn off what you don’t need
  5. Click Save settings

Status should show Ready. Scripts load only when enabled and at least one valid ID is saved.

7. Ecommerce events LiteShoper sends

Currency for most events comes from store settings. Purchase uses the order currency when set.

When GA4 event Meta event
Every storefront page (base tag) gtag config / page_view PageView
Product page view_item ViewContent
Add to cart succeeds add_to_cart AddToCart
Checkout page begin_checkout InitiateCheckout
Order thank-you page purchase Purchase

Item IDs: prefer variation SKU; otherwise ls-{variation_id}.

Purchase payload includes transaction ID (order number), value, tax, shipping, coupon (if any), and line items.

8. Verify tracking

  1. Open the storefront in a private/incognito window
  2. GA4: Tag Assistant or Admin → DebugView — confirm page_view and ecommerce hits
  3. Meta: Pixel Helper or Events Manager → Test Events — confirm PageView and conversions
  4. Walk a test path: product → add to cart → checkout → complete order → thank-you page

9. Ads & attribution tips

  • Use the same domain in GA4 / Meta as your live storefront
  • For Meta Ads, set Purchase as the conversion optimization event
  • For Google Ads, link GA4 and import conversions (or use GA4 purchase)
  • Purchase is session-deduped by order number if thank-you reloads
  • Add a consent banner separately if GDPR/CCPA requires it before loading tags

10. Admin pages

Page Path Purpose
Setup Guide analytics-pixels/setup-guide In-admin A–Z steps
Settings analytics-pixels/settings Enable, IDs, event toggles

11. Go-live checklist

  1. Plugin activated
  2. GA4 Measurement ID and/or Meta Pixel ID created
  3. IDs pasted; plugin enabled; status Ready
  4. Desired ecommerce events checked
  5. Tag Assistant / Pixel Helper confirm base tags
  6. Test purchase fires once on thank-you
  7. Ads accounts linked / conversion goals set (if advertising)

12. Troubleshooting

Issue Fix
Status “Needs IDs” Enable plugin and enter a valid G-… ID and/or numeric Pixel ID
Status “Disabled” Check Enable on Settings and save
Invalid GA4 ID ignored Must match G- + alphanumeric (saved uppercase)
No scripts on admin Expected — tags load on storefront only
Add to cart not firing Ensure cart success path fires liteshop:added-to-cart (theme/product JS); event toggle on
Purchase missing Land on thank-you with order number; toggle on; check order exists
Double purchase Plugin dedupes by order number in session; clear cache/extensions that strip sessionStorage if needed
Blocked by consent / adblock Test without blockers; load tags after consent if legally required

Official references:
Google Analytics · Tag Assistant · Meta Events Manager · Create a Meta Pixel · In-store: Analytics & Pixels → Setup Guide

← All docs

LiteShoper Help Answers from plugins, docs & FAQs

Hi! Ask me about LiteShoper plugins, licenses, or documentation.