Declarative Net Request (Host Access)

declarativeNetRequestWithHostAccess
Medium RiskCategory: Web Traffic ControlView Official Docs

Technical Context

Allows the extension to intercept and modify network traffic only on websites where the user has explicitly granted host access. It utilizes the browser's internal engine to process rules, which prevents the extension from reading actual request content.

What This Means For You

This is a safer version of an ad-blocker that only works on the specific websites you choose. It protects your privacy by letting the browser handle the filtering, ensuring the extension does not see your sensitive information.

Related APIs

This permission enables access to these Chrome APIs:

chrome.declarativeNetRequest

Common Use Cases

  • Site-specific blockers
  • Custom filters

How to Declare in manifest.json

Add the "declarativeNetRequestWithHostAccess" permission to your extension manifest:

{
  "manifest_version": 3,
  "name": "My Extension",
  "permissions": [
    "declarativeNetRequestWithHostAccess"
  ]
}

Related Permissions