Skip to content

Block or Allow JavaScript in Microsoft Edge on Computer

A page that half-loads, or a form that refuses to submit, is often a JavaScript problem. Edge lets you switch scripts off for every site at once, or for one domain only.

Open Privacy, search, and services, then Site permissions and All permissions. The JavaScript page holds the default dropdown plus the allow and block lists for individual sites.

In this guide, I have covered:

Where Edge Keeps Its JavaScript Settings

You want scripts off for a while, or back on after something broke, and the instructions you found point at menus that no longer exist. Edge moved the control. In current Edge on a computer, JavaScript sits under Privacy, search, and services, then Site permissions, then All permissions.

The JavaScript page uses a Default behavior dropdown rather than the older Turn ON or Turn OFF wording. Microsoft’s Edge privacy and site permissions guide confirms that Site permissions now appears under Privacy, search, and services.

  1. Open Microsoft Edge on your computer.
  2. Click the horizontal 3-dots icon menu in the top-right corner.
  3. Select Settings.
  4. Select Privacy, search, and services in the sidebar.
  5. Select Site permissions.
  6. Select All permissions.
  7. Select JavaScript.

Default rule on one side, site exceptions on the other. That split is the whole design of this page, and an explicit allow or block entry beats the default every time.

Stop JavaScript on Every Site

Scripts running on every page you visit is a trade you may not want to make. When the answer is “none of it”, change the default instead of typing domains into a block list one by one. This stops scripts from running. It does not make an untrusted website safe, and it will break parts of sites you actually use.

  1. Open the JavaScript page using the steps above.
  2. Find the Default behavior dropdown at the top of the page.
  3. Select Don’t allow sites to use JavaScript.
  4. Reload the tabs that need the new setting.

Open tabs keep the old rule until they reload. Once the page refreshes, menus, forms, and buttons on script-heavy sites may stop responding. That is the change working, not a fault.

You’ll know it worked when the JavaScript page reports that sites are not allowed to use scripts. Anything you allow later goes into the site list below the dropdown.

Turn JavaScript Back On for Every Site

A trusted page loads blank, or a sign-in box never appears, and everything else looks fine. That is usually JavaScript being off. Edge allows scripts by default, so a healthy setup shows Allowed (recommended) on this page.

  1. Open the JavaScript page using the steps above.
  2. Find the Default behavior dropdown at the top of the page.
  3. Select Allow sites to use JavaScript.
  4. Reload the affected tab.

Check whether the missing content comes back after the reload. If it doesn’t, look at the blocked list on the same page. A blocked domain overrides the allowed default, and that one exception will keep the page broken no matter how many times you reload.

Make an Exception for One Website

Blanket rules are blunt. Most people want one domain treated differently: a work portal that needs scripts while everything else stays quiet, or a site you don’t trust with the rest left alone. Edge keeps two lists for this, and the site entry always wins over the default.

Allow JavaScript for a specific site

Add a trusted domain to the allow list when scripts are blocked everywhere else.

  1. Open the JavaScript page under Site permissions.
  2. Scroll to Site settings.
  3. Find the list for sites allowed to use JavaScript.
  4. Select Add.
  5. Enter the site’s domain, such as example.com.
  6. Select Add to save the site.

Reload the site. You’ll know it worked when the domain shows up in the allowed list and the page’s menus and forms start responding again.

Block JavaScript for a specific site

Add a domain to the block list when you want its scripts stopped but every other site in Edge left alone.

  1. Open the JavaScript page under Site permissions.
  2. Scroll to Site settings.
  3. Find the list for sites not allowed to use JavaScript.
  4. Select Add.
  5. Enter the site’s domain, such as example.com.
  6. Select Add to save the site.

Reload and confirm the domain appears in the blocked list. If what you want is the site never opening at all, not just its scripts, Block Website access in Edge browser on Computer covers that separate setting.

note icon

Entries in either list override the default. Removing a domain from a list puts it back under the default rule, which is the quickest way to undo a one-off exception.

JavaScript and Cookies Are Separate Permissions

Two settings sit a few clicks apart and do unrelated jobs. JavaScript controls the scripts a page runs. Cookies control what sites store in your browser afterwards. Blocking one leaves the other untouched.

So if your goal is clearing or limiting stored site data, this page won’t help. Use the cookie controls instead.

These Steps Are for Edge on a Computer

The menu path above is desktop Edge, where Site permissions sits under Privacy, search, and services. The Edge app on Android hides the same setting behind a different menu, so the desktop route won’t lead you there.

On a phone, the route is different: JavaScript settings in Edge for Android live under their own screens. Same idea, different taps.

Frequently Asked Questions

The same few questions come up after a JavaScript change. Short answers below.

Where is JavaScript in Microsoft Edge settings?

In Edge Settings, JavaScript is listed under Site permissions and All permissions, within Privacy, search, and services.

How do I block JavaScript on every site in Edge?

On the JavaScript page, set Default behavior to Don’t allow sites to use JavaScript. Reload open tabs after making the change.

How do I allow JavaScript on one website when it is blocked everywhere?

Add the domain to the list for sites allowed to use JavaScript. The site exception overrides the blocked default for that domain.

Does blocking JavaScript make a website safe?

No. It stops JavaScript from running, but it does not prove that a site or its content is trustworthy. Keep using your normal security protections and judgment.

Are JavaScript and cookie permissions the same?

No. JavaScript controls scripts, while cookies control site data stored by the browser. Changing one does not change the other.

Please share the article if you find it helpful:

Disclosure: This page may contain affiliate links, which means we may receive compensation for your purchases; of course at no extra cost to you (indeed, you may get special discounts).
Kushal Azza

Kushal Azza

Kushal Azza has worked in digital analytics for 14 years. He co-founded SolvyOne Digital and is building WPAQ.com, a website audit tool. He writes about measurement, AI, workflows and building products. Follow him on X/Twitter and LinkedIn.

Leave a thought or feedback

Please leave a descriptive comment or feedback with your real name. Our human moderator vets every comment, and it may take 24 to 48 hours to get published or rejected.
Your email address will not be published, and we will never spam your inbox. Required fields are marked *