Add Google Analytics to Your Squarespace Website: Complete Guide
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:
- Navigate to Developer Tools
- Select External API Keys
- Enter your Measurement ID in the Google Analytics Account Number field
- Click Save
Note: Allow up to 24 hours for data to appear in your Analytics dashboard.
Setting Up Consent Mode:
- Add your Measurement ID
- Enable the Cookie Banner (Cookies & Visitor Data menu)
- Choose Opt-In/Opt-Out banner type
- Customize banner text (optional)
- 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:
- Open Developer Tools
- Click External API Keys
- Remove Measurement ID
- 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.