DEV Community

Dan Benitah
Dan Benitah

Posted on

Dealing with "DevTools remote debugging is disallowed by the system admin"

Developers using Playwright (often alongside GitHub Copilot) in corporate environments may encounter the error “DevTools remote debugging is disallowed by the system admin.” This cryptic message usually means your company’s group policies are blocking Chrome or Edge from running in remote-debug/automation mode. In such locked-down setups, Playwright’s attempt to launch a Chromium-based browser gets shut down by admin rules, leading to that error in your test logs.

Quick Fix: Use WebKit Instead of Chrome/Edge

Rather than wrestling with IT to relax the policies or applying hacky workarounds, the easiest solution is to avoid the restricted browsers entirely. Playwright supports multiple browser engines (Chromium, Firefox, WebKit). By configuring the Playwright MCP server to run tests on WebKit, you bypass the corporate restrictions affecting Chrome/Edge. The WebKit engine that ships with Playwright isn’t subject to those admin policies (since they specifically target Chromium-based browsers), so your tests can run without hitting the “remote debugging disallowed” roadblock.

For example, update your MCP server config to specify WebKit as the browser:

{
  "mcpServers": {
    "playwright": {
      "command": "npx",
      "args": [
        "@playwright/mcp@latest",
        "--browser=webkit"
      ]
    }
  }
}
Enter fullscreen mode Exit fullscreen mode

In plain terms, using WebKit avoids the issue because it’s a different browser engine (essentially Safari’s open-source core) that corporate group policies don’t block. With this one change, you can run your Playwright tests (even those generated via Copilot) smoothly – no more admin interference, just automated tests running as expected.

If this did not work for you, you can always edit the relevant registry keys, request to "Allow Browser Remote Debugging" or use the extension

Top comments (0)