Block JavaScript on specific sites
Jump to overview

Policy overview

Key metadata and intent for this policy.

Category
Microsoft Edge > Content settings
Supported on
Microsoft Edge version 77, Windows 7 or later

Supported OS tags: Windows7

Defines a list of sites, based on URL patterns, that aren't allowed to run JavaScript. If you don't configure this policy, 'DefaultJavaScriptSetting' (Default JavaScript setting) applies for all sites, if it's set. If not, the user's personal setting applies. For detailed information on valid url patterns, see https://go.microsoft.com/fwlink/?linkid=2095322. Wildcards, *, are allowed. This policy blocks JavaScript based on whether the origin of the top-level document (usually the page URL that's also displayed in the address bar) matches any of the patterns. Therefore, this policy isn't appropriate for mitigating web supply-chain attacks. For example, supplying the pattern `https://[*.]foo.com/` doesn't prevent a page hosted on, say, `https://contoso.com`, from running a script loaded from `https://www.foo.com/example.js`. Furthermore, supplying the pattern `https://contoso.com/` doesn't prevent a document from `https://contoso.com` from running scripts if it isn't the top-level document, but embedded as a subframe into a page hosted on another origin, say, `https://www.fabrikam.com`. Example value: https://www.contoso.com [*.]contoso.edu

Internal name
JavaScriptBlockedForUrls
Policy ID
c8584e049db1
Elements
1

Registry values

How enabled and disabled states update the registry.

No explicit registry values are set for enabled or disabled states.

Policy elements

Inputs and configuration options exposed by this policy.

ScopeElementTypeRegistry mappingConstraints & behaviorCopy
Block JavaScript on specific sites
ID JavaScriptBlockedForUrlsDesc
list
Path
Software\Policies\Microsoft\Edge\JavaScriptBlockedForUrls
Value name
1, 2, …
Type
REG_SZ
List: standard
Block JavaScript on specific sites
Both · Type list
Registry mapping
Path
Software\Policies\Microsoft\Edge\JavaScriptBlockedForUrls
Value name
1, 2, …
Type
REG_SZ
Details
List: standard