Skip to content

Analytics

Go to Settings → Analytics.

The Site Settings modal opened to Analytics and Tracking settings.
Analytics settings are injected into exported and deployed pages.
ProviderFieldFormat
Google Analytics 4Google Analytics IDG-XXXXXXXXXX
Google Tag ManagerGTM IDGTM-XXXXXXX
Facebook PixelFacebook Pixel IDnumeric ID
HotjarHotjar IDnumeric site ID
Any providerCustom analyticsPaste raw <script> tags
  1. In your Google Analytics account, copy your Measurement ID (starts with G-).

  2. Open Settings → Analytics in Swebsy.
  3. Paste the ID into the Google Analytics ID field.
  4. Click Save.

Analytics scripts are injected at export and deploy time. They do not run inside the Swebsy editor or editor Preview mode, so test tracking on the exported or deployed site.

Paste any <script> tag (or raw tracking code) into the Custom analytics field. It’s injected into <head> on every exported or deployed page.

If you use a strict Content Security Policy in Settings → Performance, add the analytics provider’s script and connection domains there too.

Common issues

Analytics not firing — tracking only activates on your exported or deployed site. It won’t fire inside the Swebsy editor or Preview mode.

Double-tracking — if you’re also using Settings → Advanced → Custom <head> code to inject tracking, remove the duplicate so your events aren’t counted twice.