Overview
In today’s digital landscape, ad blockers have become a staple for many internet users, particularly Apple iOS users who benefit from enhanced privacy features that prevent tracking by tools like Google Tag Manager (GTM), Google Analytics, and Facebook Pixel. While ad blockers offer a cleaner browsing experience, they create significant challenges for website owners who depend on these tracking scripts to gather insights about their audience and measure conversions.
This blog post dives into how ad blockers work, the problems they pose for tracking, and a practical solution—using a custom subdomain—to bypass them. We’ll also provide a step-by-step guide to setting up a custom subdomain for GTM, backed by recent statistics and expert insights, to make your analytics more robust and reliable. Understanding Ad Blockers: The Gatekeepers of the Web Ad blockers are applications or browser extensions that prevent ads and tracking scripts from loading on websites. They achieve this by intercepting HTTP requests and checking them against predefined filter lists, which include known ad-serving or tracking domains like tagmanager.google.com or analytics.google.com. If a request matches a blocked domain, the ad blocker stops it, preventing the script from loading.
To make this easier to understand, let’s use an analogy inspired by your video. Imagine your browser as a school with a strict gatekeeper. The gatekeeper only allows students wearing the school’s uniform (requests from the website’s domain) to enter. Tracking scripts, like Google Tag Manager, wear a different uniform (a third-party domain), so the gatekeeper blocks them. This is why scripts from external domains are often stopped by ad blockers, leaving website owners with incomplete data. Ad blockers operate through several methods:
Predefined Lists:
These contain domains and formats associated with ads or trackers, such as facebook.com or doubleclick.net. If a request matches, it’s blocked before it loads (Funnel.io). Content Blocking: Ad blockers use scripts to identify and block specific page elements, like JavaScript tags, that signal an ad or tracker. Custom Rules: Some ad blockers allow users to create their own rules, such as blocking Google AdSense but allowing other content.
This functionality is available as browser extensions (e.g., AdBlock Plus, uBlock Origin), standalone apps, or even features within VPNs and antivirus software (Cybernews). The Problem: Ad Blockers Disrupt Tracking When ad blockers prevent tracking scripts from loading, website owners lose critical data about their visitors. This includes metrics like page views, traffic sources, and user actions (e.g., purchases or sign-ups). For businesses that rely on analytics to optimize marketing campaigns or improve user experience, this can lead to misguided decisions based on incomplete information. The scale of this issue is significant, as shown by recent statistics:
Global Usage:
Approximately 31.5% of internet users worldwide (aged 16–64) use ad blockers at least sometimes, with usage expected to grow (Backlinko). User Numbers: In Q2 2023, an estimated 912 million people used ad blockers globally, with 416 million on desktop and 496 million on mobile (Backlinko). Revenue Impact: Ad blockers are projected to cost publishers $54 billion in lost advertising revenue in 2024, accounting for about 8% of total digital ad spend (Backlinko). Demographics: Men are more likely to use ad blockers (49%) than women (33%), and usage is higher in developed countries due to privacy concerns (B2.ai). Mobile Growth: Mobile ad blocking has seen a 30% year-over-year increase since 2022, reflecting the shift to mobile browsing (B2.ai).
These numbers underscore the urgency for website owners to find solutions that ensure their tracking scripts can function despite ad blockers. The Solution: Using a Custom Subdomain A proven method to bypass ad blockers is to host tracking scripts on a custom subdomain of your main website, such as tracking.yourwebsite.com, instead of relying on third-party domains like tagmanager.google.com. Since ad blockers typically allow scripts from the same domain or subdomain (to avoid breaking website functionality), this approach makes your tracking scripts appear as part of your site, reducing the likelihood of being blocked. How It Works When you configure your tracking scripts to load from a custom subdomain, the requests are sent from a domain that matches your website’s “uniform.” In the school analogy, this is like giving your tracking scripts the school’s uniform so the gatekeeper lets them through. For example, your video demonstrated how switching GTM from tagmanager.google.com to load.trackingacademy.com allowed the script to load successfully, even with an ad blocker enabled. This method is effective because:
Ad blockers rely on filter lists that target third-party domains, not first-party subdomains (Fathom Analytics). Most ad blockers avoid blocking scripts from the same domain to prevent breaking essential website features (Simple Analytics).
Services like Fathom Analytics and Simple Analytics have implemented this approach for their tracking scripts, and similar solutions exist for GTM, such as Stape.io.
Setting Up a Custom Subdomain for Google Tag Manager
Setting up a custom subdomain for GTM involves configuring your domain’s DNS settings and updating your GTM container. While the process can be technical, tools like Stape.io can simplify it. Below is a step-by-step guide based on best practices from Google Developers and Stape.io. Step-by-Step Guide
Choose a Subdomain:
Select a subdomain name, such as gtm.yourwebsite.com or tracking.yourwebsite.com. Ensure it’s descriptive and aligns with your website’s branding.
Set Up DNS Records:
Access your domain registrar’s DNS settings (e.g., GoDaddy, Namecheap). Add a CNAME record to point your subdomain to the GTM server. For server-side GTM, this might be a Google Cloud server or a service like Stape.io’s server. Example CNAME record:
Configure GTM:
If using server-side GTM, create a server container in GTM and set up a tagging server (Google Developers). Update the GTM container to load scripts from your custom subdomain. This may involve modifying the GTM embed code or using a custom loader. If using a service like Stape.io, log into your account, select your container, and add the custom subdomain under the “Custom Loader” settings (Stape.io).
Test the Setup:
Open your website in a browser and use developer tools (e.g., Chrome DevTools, Network tab) to verify that the GTM script loads from your custom subdomain (e.g., gtm.yourwebsite.com). Enable an ad blocker (e.g., uBlock Origin) and refresh the page to confirm the script still loads. Check the status code in the Network tab; a “200 OK” status indicates success (Stape.io).
Tools to Simplify the Process
Stape.io: Offers a user-friendly interface to configure custom domains for GTM, including automatic DNS setup via supported providers (Stape.io). Fathom Analytics: Provides custom domain support for its privacy-focused analytics, which can be adapted for GTM-like setups (Fathom Analytics). Simple Analytics: Allows custom subdomains to bypass ad blockers for its tracking scripts, with a similar approach applicable to GTM (Simple Analytics).
Best Practices
Verify DNS Configuration: Ensure your CNAME record is correctly set up and propagated (this can take up to 48 hours). Use a CDN: For faster script loading, consider using a Content Delivery Network (CDN) like Stape’s Global CDN (Stape.io). Monitor Performance: Regularly check your GTM container to ensure scripts are loading and tracking data accurately. Debug with Tools: Use GTM’s Preview mode or browser developer tools to troubleshoot any issues.
Benefits of Using a Custom Subdomain
Implementing a custom subdomain for your tracking scripts offers several advantages:
Improved Tracking Accuracy: By bypassing ad blockers, you capture more data about your visitors, leading to better insights (Hallam). Better Cookie Management: Custom subdomains enable first-party cookies, which have longer lifespans and are less likely to be blocked by browsers like Safari or Firefox (Google Developers). Enhanced Privacy Compliance: First-party tracking reduces reliance on third-party cookies, aligning with privacy regulations like GDPR and CCPA (Fathom Analytics). Increased Reliability: Custom subdomains are less affected by browser privacy settings, such as Intelligent Tracking Prevention (ITP), which limits third-party tracking (Stape.io).
Considerations and Potential Challenges
While the custom subdomain approach is effective, there are some factors to keep in mind:
Setup Complexity: Configuring DNS records and GTM containers requires technical knowledge. Non-technical users may need to rely on tools like Stape.io or hire a developer. Maintenance: DNS records and GTM configurations must be kept up to date, especially if you change hosting providers or GTM setups. Evolving Ad Blockers: Ad blockers may update their filter lists to target custom subdomains, though this is less common since it risks breaking website functionality (Fathom Analytics). Browser Privacy Features: Browsers like Firefox, Brave, and Safari have built-in tracking prevention that may still block some scripts, though custom subdomains are generally more resilient (Hallam).
To mitigate these challenges, stay informed about ad blocker trends and test your tracking setup regularly. Services 2015-2024 Real-World Example: Your Video in Action Your video provides a practical demonstration of this solution. By switching the GTM script from tagmanager.google.com to load.trackingacademy.com, you showed how the script loaded successfully even with an ad blocker enabled. This real-world example highlights the effectiveness of the custom subdomain approach and serves as a valuable reference for readers looking to implement this solution. Additional Strategies to Complement Custom Subdomains While custom subdomains are a powerful tool, you can enhance your tracking strategy with these complementary approaches:
Server-Side Tracking: Move tracking logic to the server side to further reduce reliance on client-side scripts (Hallam). Consent Management: Implement a cookie consent platform to comply with privacy laws and build user trust, which may reduce ad blocker usage. Alternative Analytics: Consider privacy-focused analytics tools like Fathom Analytics, which are less likely to be blocked (Fathom Analytics).
Conclusion
Ad blockers are a growing challenge for website owners, but they don’t have to derail your analytics efforts. By using a custom subdomain for your tracking scripts, you can bypass many ad blockers, ensuring more accurate data and better insights into your audience. While setting up a custom subdomain requires some technical effort, the benefits—improved tracking, better cookie management, and enhanced privacy compliance—make it a worthwhile investment. Tools like Stape.io and Fathom Analytics can simplify the process, and regular testing will keep your setup running smoothly. With this approach, you can take control of your website’s analytics and make data-driven decisions with confidence.
Need help implementing the tracking? Send us a message..!
Send a Message