How AdOff Works: The Technology Behind Stealth Ad Blocking
Most ad blockers operate with a single blunt tool: a list of URLs to block. They do the job until a website figures out they exist — and then the arms race begins. AdOff was built differently from the ground up, using four independent layers of protection that work together to deliver a truly invisible, interruption-free browsing experience.
This page breaks down exactly how each layer works — with enough technical detail for the curious, but written so that anyone can follow along. Whether you're a developer who wants to understand the architecture or a regular user who just wonders why AdOff keeps working when other blockers give up, you're in the right place.
Layer 1 — Network Blocking
Active on all plansThe first and most efficient layer operates at the network level, stopping ad-related HTTP requests before they are even downloaded by your browser. No data is fetched, no scripts are executed, no tracking pixels are loaded. The resource is simply never retrieved.
🔧 Chrome API: declarativeNetRequest
AdOff uses Chrome's declarativeNetRequest API — the same modern API used by enterprise
security tools. Unlike the older webRequest API, declarativeNetRequest is evaluated
natively by the browser engine without any JavaScript overhead. Rules are compiled once on install and
matched at near-zero CPU cost for every subsequent request.
107+ Precision Blocking Rules
AdOff ships with 107 hand-curated network rules targeting the ad delivery infrastructure used by the most common advertising networks. Rather than maintaining an enormous list of individual domains that requires constant maintenance, AdOff's rules target the structural patterns of ad delivery:
- Ad server domains — the hostnames that serve banner ads, video pre-rolls, and sponsored content
- Tracking and analytics endpoints — pixels, beacons, and event collectors that profile your behaviour
- Retargeting infrastructure — cross-site trackers that follow you from site to site
- Programmatic ad exchange URLs — real-time bidding endpoints that auction ad impressions
- CDN paths used exclusively for ads — content delivery patterns specific to ad payloads
Why Blocking at the Network Level Matters
When an ad is blocked at the network layer, the page loads faster. This isn't just about removing a visible banner — it means the browser never has to open TCP connections to ad servers, never performs DNS lookups for tracking domains, and never executes the third-party JavaScript that ads depend on to render and measure themselves.
Studies on ad-heavy news sites consistently show that network-level blocking reduces page load times by 30–60%. Each blocked ad request is a connection that never needs to be opened, a script that never needs to be parsed, and a payload that never consumes your bandwidth.
⚡ Performance advantage
Because declarativeNetRequest rules are evaluated by the browser's C++ engine — not by JavaScript — AdOff adds zero CPU overhead during normal browsing. The matching happens before the network stack even begins the request. No JavaScript is executed per page, and the extension uses effectively no memory while idle.
Layer 2 — Cosmetic Filtering
Active on all plansNot all ads arrive via network requests that can be pre-blocked. Some ads are rendered directly inside the page's own HTML, loaded from the same domain as the content, or injected by first-party JavaScript. For these, AdOff uses cosmetic filtering — the technique of hiding ad elements from the DOM using CSS, without disrupting the surrounding layout.
CSS Injection in the Isolated World
AdOff's content script runs in Chrome's ISOLATED world — a sandboxed execution environment that is completely separate from the page's own JavaScript. This means the extension can observe and modify the DOM without being detectable by the page's scripts, which have no access to the isolated world's scope or variables.
The cosmetic filter injects a CSS stylesheet that applies display: none and
visibility: hidden rules to known ad container selectors. These selectors are carefully
maintained to cover the standard class names, IDs, and structural patterns used by ad slots across
thousands of websites.
🎨 No layout shift — no blank spaces
A common problem with naive ad blockers is that removing an element from the DOM causes the surrounding
content to jump or reflow. AdOff's CSS rules use display: none with
!important priority and are applied before the browser's first paint where possible,
preventing any visible layout shift. The space the ad would have occupied simply doesn't appear.
DOM Scanning and Dynamic Injection
Modern websites are heavily dynamic — they load content after the initial HTML is parsed, inject ad slots via JavaScript, and update the DOM continuously. AdOff's content script monitors the DOM for newly inserted elements that match ad patterns and applies hiding rules immediately, typically within a single animation frame. You won't see ads flash briefly before disappearing.
Video Ad Neutralization (Pro)
Most video players on streaming platforms and broadcaster websites rely on a standard ad SDK to manage pre-roll, mid-roll, and post-roll video interruptions. AdOff Pro replaces this SDK with a neutral stub that immediately tells the player "no ads to show" — so the video starts directly without any interruption.
This works through two complementary mechanisms:
- Network-level redirect — requests to load the ad SDK are intercepted and redirected to a local stub file bundled with the extension
- Page-level injection — the stub is injected before any site script runs, so even players that bundle the ad SDK internally find the neutral version first
The stub implements the full API surface of the original SDK but never serves any ad.
When the player calls start(), the stub immediately fires the "ad complete" signal
— the player resumes the video as if the ad break ended naturally.
This is universal: it works on any website worldwide that uses this SDK,
without requiring a manual list of sites.
On major video platforms, a dedicated handler accelerates ad playback at 16× speed and automatically clicks the skip button with human-like timing.
Layer 3 — Stealth Anti-Detection (Pro)
Pro & TrialThis is where AdOff diverges most significantly from conventional ad blockers. Many websites now run active anti-adblock scripts — code whose sole purpose is to detect whether you're running a blocker and, if so, to interrupt your experience with a wall, a warning, or degraded content.
AdOff's stealth layer, running in Chrome's MAIN world, operates at the same level as the page's own JavaScript. It surgically neutralises anti-adblock detection before it can run. Here's how each technique works:
🪤 Bait Spoofing
Anti-adblock scripts commonly work by injecting a small "bait" element — a DOM node styled to look like an ad container — and then checking whether its dimensions are zero, or whether it was removed by an ad blocker. AdOff's bait spoofer preserves these elements in the DOM, reports plausible dimensions when their geometry is queried, and ensures the detection script receives the "all clear" signal it expects.
📦 Variable Spoofing
Ad networks inject global JavaScript variables and properties onto the window object to
signal their presence. Anti-adblock scripts check for the existence of these variables to confirm
that ads were loaded. AdOff's variable spoofer reconstructs the expected global namespace — creating
lightweight stub objects that pass the presence checks — so the page believes ad scripts ran
successfully even though no actual ad content was delivered.
🔌 Fetch / XHR Interception
Some detection systems don't rely on the DOM at all — they make a direct fetch() or
XMLHttpRequest call to a known ad endpoint and measure the response time or status code.
If the request was blocked, it fails instantly, betraying the blocker's presence. AdOff wraps both
window.fetch and XMLHttpRequest with proxy handlers that detect requests
to known ad domains and return synthetic responses that mimic a successful ad load.
🛡️ Script Neutralizer
Known anti-adblock scripts are identified by their URL patterns and payload signatures. When the browser attempts to load one of these scripts, the stealth layer intercepts execution and replaces the script's logic with an inert stub that satisfies any completion callbacks without performing any detection work. The page's code receives a resolved promise or a no-op callback, and the detection path is never reached.
👁️ MutationObserver — Real-Time Defense
Websites can inject new detection scripts at any time after the initial page load — triggered by user
actions, scroll depth, or timers. AdOff's MutationObserver continuously watches for new
<script> elements being added to the document. When one matches a known anti-adblock
signature, the stealth layer neutralises it before its first instruction executes. This ensures
protection holds even against deferred or lazy-loaded detection systems.
How the Three Layers Work Together
Each layer is independent — if one is bypassed or not applicable, the others continue working. But their real power is in how they complement each other:
- Network blocking eliminates most ad payloads before they exist in the browser, reducing the attack surface for detection scripts that can only detect what was blocked.
- Cosmetic filtering handles first-party ads and any remnants that slip through the network layer, keeping the visual experience clean without leaving tells in the DOM.
- Stealth anti-detection wraps the other two layers in a cloak of invisibility, convincing the page that no blocker is present at all — so the anti-adblock paywall never triggers.
The result is a browsing experience that isn't just ad-free — it's one where websites never know you're using an ad blocker. No warnings, no paywalls, no degraded content, no "please disable your ad blocker" overlays.
Privacy by Design
AdOff processes everything locally in your browser. There are no remote servers analysing your browsing history, no telemetry sent home, and no list of visited URLs ever leaves your device. The extension requests only the permissions it genuinely needs:
- declarativeNetRequest — to enforce network blocking rules
- storage — to save your preferences and ad counter locally
- tabs — to display the per-site badge count
- scripting — to inject cosmetic filters and stealth scripts
No "read all your data on all websites" catch-all. No analytics SDK bundled inside the extension. What happens in your browser stays in your browser.
Getting Started in 3 Steps
-
Install AdOff from the Chrome Web Store or download the
.zipdirectly from adoff.app/install. Chrome will ask for permission confirmation — review and accept. - Pin the extension by clicking the puzzle-piece icon in your Chrome toolbar, locating AdOff in the dropdown, and clicking the pin icon. The AdOff shield will appear permanently in your toolbar.
- Browse normally. All four layers activate automatically on every page you visit. Click the AdOff icon at any time to see how many ads and requests have been blocked, or to pause protection on a specific site.
No configuration is required for the default experience. Advanced users can explore the options page to manage their whitelist, adjust blocking behaviour per site, or activate the stealth Pro features during the free 15-day trial.
Ready to experience the difference?
Try all four layers of protection free for 15 days. No credit card required.
Install AdOff Free →