⚠️ v1.0.0 UPDATE - This FAQ references some legacy routes that were removed in v1.0.0Key Changes:
- ❌ Legacy routes removed:
/cdn/gtag/js,/cdn/gtm.js,/cdn/fbevents.js- ✅ UUID-based routes only:
/cdn/f/{UUID},/cdn/g/{UUID}- ✅ See MIGRATION-V3.md for complete details
Some examples below use old paths for clarity - replace with your UUID-based paths.
Common questions and answers about Tracklay.
A first-party proxy that serves Google Tag Manager, Google Analytics, and other tracking scripts from your own domain instead of third-party domains. This bypasses ad-blockers and browser tracking protections.
Modern browsers (Safari, Firefox) and ad-blockers block third-party tracking scripts, causing you to lose 20-40% of conversion data. This proxy serves scripts as first-party, making them unblockable.
Yes. You're serving the same tracking scripts, just from your own domain. However, you still need to comply with privacy laws (GDPR, CCPA) and obtain user consent for tracking.
Yes! This was built specifically for Shopify stores, but works with any e-commerce platform.
The Cloudflare Workers free tier includes 100,000 requests/day, which is enough for most stores. Paid plans start at $5/month for unlimited requests.
- Your store loads scripts from your domain (e.g.,
yourstore.com/cdn/g/{UUID}) - Cloudflare Worker proxies the request to Google's servers
- Worker adds proper CORS headers and returns the script
- Browser treats it as first-party and doesn't block it
Note: v1.0.0 uses UUID-based obfuscated paths instead of detectable patterns.
- GTM scripts (
/gtm.js,/gtag/js) - Analytics endpoints (
/collect,/g/collect) - Custom endpoints you configure
No. Cloudflare Workers run on the edge (near your users) with < 10ms processing time. Scripts are also cached.
Yes! The proxy works standalone. GTM Server-Side is optional but recommended for better tracking.
Currently:
- Google Tag Manager (GTM)
- Google Analytics (GA4, Universal Analytics)
- Google Ads conversion tracking
Planned:
- Meta Pixel (Facebook)
- TikTok Pixel
- Custom tracking providers
No. The setup script handles everything automatically. You just need to:
- Run the setup script
- Deploy to Cloudflare
- Update your theme
5-10 minutes for automatic setup, including:
- Installation: 2 minutes
- Configuration: 1 minute
- Deployment: 1 minute
- Theme update: 2-5 minutes
That's fine! You can:
- Use the proxy standalone (works great)
- Set up GTM Server later (optional)
- Leave
GTM_SERVER_URLempty in config
Yes! Deploy to a staging environment:
npm run deploy:stagingTest on a development store first.
The worker automatically detects your domain from the request URL. No manual CORS configuration needed!
Just set:
ALLOWED_ORIGINS: []; // Empty = auto-detectOnly if:
- You have specific security requirements
- You need to allow only certain subdomains
- Auto-detection isn't working for your setup
Edit src/config/index.js:
CDN_PATHS: ['/cdn/', '/assets/', '/custom-path/'];Then update your Cloudflare routes.
Default is 100 requests/minute per IP. Adjust based on your traffic:
- Small store (< 1000 visitors/day): 100-200
- Medium store (1000-10000 visitors/day): 200-500
- Large store (> 10000 visitors/day): 500-1000
npm run deployThat's it! Automatic deployment via GitHub Actions is also available.
Yes! Configure routes in Cloudflare Dashboard:
yourstore.com/cdn/*→ Your Worker
Just redeploy:
npm run deployGitHub Actions can also deploy automatically on push to main.
Yes. In Cloudflare Dashboard:
- Go to Workers > Your Worker
- Click Deployments
- Click Rollback on previous version
- Route configured? Check Cloudflare Dashboard > Workers > Routes
- Worker deployed? Run
npm run deploy - DNS correct? Domain must be on Cloudflare
Test:
# Replace YOUR-UUID with your actual Google UUID (see: node scripts/get-urls.js)
curl https://yourstore.com/cdn/g/YOUR-UUID?id=G-XXXXXMost common causes:
- Auto-detection disabled but domain not in
ALLOWED_ORIGINS - Request origin doesn't match allowed origins
- Browser cached old CORS headers
Fix:
// Enable auto-detection
ALLOWED_ORIGINS: [];Increase limit in src/config/index.js:
RATE_LIMIT_REQUESTS: 200, // Increase thisThen redeploy.
Check:
GTM_SERVER_URLis correct- GTM Server is running
- No firewall blocking Cloudflare IPs
Test directly:
curl https://gtm.yourstore.com/healthnpm run tailOr in Cloudflare Dashboard > Workers > Logs.
- Edge processing: < 10ms
- Total time (edge to origin): < 50ms
- Cached scripts: < 5ms
Faster than loading directly from Google in most cases!
Yes. Static scripts (gtm.js, gtag.js) are cached for 1 hour by default. Tracking endpoints are never cached.
Yes. Cloudflare Workers auto-scale. No server to crash or slow down.
Cloudflare has 200+ edge locations worldwide. Your worker runs near every user.
Yes:
- SHA-256 UUID generation with rotating salt
- Rate limiting per IP
- Request size limits
- Timeout protection
- Security headers (CSP, X-Frame-Options)
See SECURITY.md for details.
Protection against abuse:
- Rate limiting (100 req/min per IP)
- Request size limits (1MB)
- Timeout protection (10s)
- Input validation
- Generate random secret (setup script does this)
- Set in Cloudflare (not in code)
- Rotate every 90 days
# Generate new secret
openssl rand -base64 32 | tr -d "=+/" | cut -c1-32
# Set in Cloudflare
wrangler secret put OBFUSCATION_SECRETThe proxy itself is just infrastructure. You're responsible for:
- Obtaining user consent
- Privacy policy
- Cookie notices
- Data retention
- Opt-out mechanisms
Free Tier:
- 100,000 requests/day
- Enough for most small-medium stores
Paid Plan ($5/month):
- Unlimited requests
- Better support
- More features
Optional:
- Custom domain: Free (if already on Cloudflare)
- GTM Server: ~$50-200/month (Google Cloud)
- SSL certificate: Free (Cloudflare provides)
Estimate:
- 1000 visitors/day × 3 tracking events = 3000 requests/day
- Well within free tier
Monitor in Cloudflare Dashboard.
Segment is a CDP (Customer Data Platform). This is a simple proxy. Use this if you:
- Just need to bypass ad-blockers
- Want a free solution
- Already have GTM/GA setup
GTM Server-Side is a tracking server. This proxy serves scripts and endpoints. They work together:
- Proxy: Serves scripts from your domain
- GTM Server: Processes tracking data server-side
Use both for best results!
Yes, but there's usually no need. This proxy is designed to work standalone or with GTM Server.
Yes! Edit the routing:
// src/routing/mapping.js
export const URL_MAPPINGS = {
'/tiktok/pixel': 'https://analytics.tiktok.com/pixel.js',
// Add your mappings
};Yes. Edit src/proxy/response-builder.js to modify headers or content.
Yes. Add to src/middleware/ and import in worker.js.
See CONTRIBUTING.md for guidelines.
- Documentation: README.md
- Quick Start: QUICK_START.md
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Use the bug report template:
- Go to Issues
- Click New Issue
- Choose Bug Report
- Fill in details
Use the feature request template:
- Go to Issues
- Click New Issue
- Choose Feature Request
- Describe your idea
Yes! Many Shopify experts can help. This is a standard Cloudflare Worker deployment.
Problem: Safari ITP blocks third-party cookies
Solution: This proxy serves tracking as first-party, bypassing ITP
Problem: Ad-blockers block google-analytics.com
Solution: Proxy serves from your domain (e.g., yourstore.com/cdn/)
Problem: Missing 20-40% of conversions
Solution: First-party tracking captures more accurate data
Problem: Need to allow shop.example.com and www.example.com
Solution:
ALLOWED_ORIGINS: ['https://shop.example.com', 'https://www.example.com'];Or use auto-detection (recommended).
Still have questions?
Open a discussion or issue!