Add Google Analytics to Your Squarespace Website: Complete Guide

By Michael Thompson

December 12, 2024 at 10:59 AM

Connect your website with Google Analytics to track and analyze visitor data effectively.

Before Starting:

  • Create a Google Analytics account at google.com/analytics
  • Have your Measurement ID ready (starts with G-)

Adding Your Google Analytics Measurement ID:

  1. Navigate to Developer Tools
  2. Select External API Keys
  3. Enter your Measurement ID in the Google Analytics Account Number field
  4. Click Save

Note: Allow up to 24 hours for data to appear in your Analytics dashboard.

Setting Up Consent Mode:

  1. Add your Measurement ID
  2. Enable the Cookie Banner (Cookies & Visitor Data menu)
  3. Choose Opt-In/Opt-Out banner type
  4. Customize banner text (optional)
  5. Save changes

Excluding Your Own Traffic: Create a filter in Google Analytics to exclude your IP address to prevent mixing your page views with visitor data.

E-Commerce Tracking: Squarespace automatically sends to Google Analytics:

  • Order numbers
  • Shop name
  • Purchase totals (including shipping)
  • Customer location data
  • Product details (name and SKU)

Disconnecting Google Analytics:

  1. Open Developer Tools
  2. Click External API Keys
  3. Remove Measurement ID
  4. Save changes

Key Differences Between Platforms:

  • Internal Traffic: Squarespace excludes logged-in activity; Google Analytics includes it
  • Bot Filtering: Different methods used by each platform
  • Data Sampling: Squarespace uses full data; Google Analytics may estimate from samples
  • E-Commerce Tracking: Some discrepancies may occur in order tracking
  • Location Data: Different IP address collection methods may show varying results

Ajax Loading Notice: For version 7.0 websites, Ajax Loading may interfere with accurate analytics tracking. Consider disabling it for better results.

Related Articles

Previous Articles