The chrome-error://chromewebdata/ page in Chrome or Cypress usually means the target server was not ready, the browser was blocked by an origin policy, or headless Chrome hit a container restriction. Verify the server first, use cy.origin() for cross-origin Cypress steps, and reserve flags such as --no-sandbox and --disable-dev-shm-usage for the CI environment that actually needs them.
How to Fix chrome-error://chromewebdata/ in Chrome & Cypress
Fix chrome-error://chromewebdata/ in regular Chrome and Cypress tests. Covers server timing, cy.origin(), Docker CI flags, and browser cache fixes.
// The short answer
In this guide · 4 sections
Hitting that ugly chrome-error://chromewebdata/ screen halfway through a Cypress run is super frustrating, but it almost always boils down to one of two things: your tests tried hitting a server before it was actually ready, or the browser tripped over a cross-origin policy. Instead of leaning on old, hacky workarounds that break down anyway, you can clean this up pretty easily with modern origin handling and a couple of essential pipeline tweaks.
Main Culprits: Server boot lags, strict
X-Frame-Optionsheaders, and Docker running out of headless memoryThe Modern Cypress Fix: Reach for
cy.origin()What to Stop Doing: Don't rely on
chromeWebSecurity: falseanymoreEssential CI/CD Flags: Toss in
--no-sandboxand--disable-dev-shm-usageQuick Local Check: Wipe out browser cache and turn off any interfering VPN extensions
What Actually Causes the chrome-error://chromewebdata/ Error?
1. Server Startup Race Conditions
If you kick off Cypress while spinning up a local dev server, you're practically inviting a race condition. The test runner fires up, attempts to load the target URL, and finds nobody home because the backend or bundler is still waking up. Chrome gives up waiting, gets zero response, and immediately falls back to this generic internal error page.
2. Cross-Origin Jumps and X-Frame-Options
Modern sites are pretty protective about where and how they can be framed. When an app sends back an X-Frame-Options: sameorigin header, Chrome flat-out refuses to render it inside Cypress's test iframe. It’s definitely annoying to run into mid-test, but the browser is just doing its job from a security standpoint - it’s intended behavior, not a bug.
3. Docker Memory Bottlenecks in Headless Mode
We've all seen tests pass locally only to completely tank in CI. Headless Chrome inside a bare-bones Docker container doesn't get the generous shared memory your local machine offers. Once the container eats through its tiny allocated shared memory partition, Chrome silently crashes the renderer process and dumps you straight onto that chromewebdata screen.
How to Fix It in Cypress (The Right Way)
Solution 1: Handle Multiple Domains with cy.origin()
Back in the day, jumping domains in a single Cypress spec was an absolute nightmare. Today, cy.origin() handles this cleanly out of the box. It basically tells Cypress, "Hey, expect a new domain here, run these specific interactions inside that context, and bring the execution flow right back when you're finished."
JavaScript
cy.origin('https://other-domain.com', () => {
cy.get('[data-cy=login-btn]').click()
})By isolating third-party actions inside that callback, you completely steer clear of iframe framing collisions. It keeps your specs rock-solid, plays nicely with modern browser security standards, and saves you from writing fragile hacky bypasses.
Solution 2: Make Cypress Wait with wait-on
Kicking off your dev server and running Cypress in the exact same command without any synchronization is asking for trouble. Grab the wait-on utility from npm so your test runner knows to sit tight until the local port is actually up and ready to serve traffic.
Bash
npm install --save-dev wait-onWire it directly into your package.json scripts so Cypress holds its horses until wait-on confirms the server is actively accepting connections:
JSON
{
"scripts": {
"test:e2e": "wait-on http://localhost:3000 && cypress run"
}
}That single change takes server boot timing issues completely off the table.
Why You Should Stop Using chromeWebSecurity: false
A lot of older Stack Overflow posts still tell you to flip chromeWebSecurity: false in your config, but treat that as legacy advice. Turning off web security leaves your setup fragile, fails to mimic how users actually experience your app, and still crashes if an external service enforces rigid X-Frame-Options headers. Switching over to cy.origin() gives you reliable tests without poking artificial holes in browser security.
Fixing Docker and CI/CD Pipeline Crashes
Browser Flags Every Headless Run Needs
If you're running your suite in GitHub Actions, GitLab CI, or another containerized runner, you have to hand Chrome a couple of specific launch flags. Passing --disable-dev-shm-usage forces Chrome to leverage /tmp instead of choking on the tiny default /dev/shm partition. Pairing that with --no-sandbox sidesteps container privilege headaches that crash headless sessions.
JavaScript
// cypress.config.js
const { defineConfig } = require('cypress')
module.exports = defineConfig({
e2e: {
setupNodeEvents(on, config) {
on('before:browser:launch', (browser, launchOptions) => {
if (browser.name === 'chrome' && browser.isHeadless) {
launchOptions.args.push('--no-sandbox')
launchOptions.args.push('--disable-dev-shm-usage')
}
return launchOptions
})
}
}
})Tucking those two arguments into your launch config clears up the vast majority of mysterious headless CI crashes.
Quick Checks for Everyday Browser Errors
Extension and VPN Conflicts
If you're running into this error during ordinary day-to-day browsing, background utilities are usually the culprits. Aggressive ad blockers and VPN extensions intercept web requests and can accidentally knock internal browser routing off track.
Try turning off your extensions, reload the tab, and see if things return to normal. If you happen to spot DNS_PROBE_FINISHED_NXDOMAIN showing up alongside it, you're almost certainly dealing with a broken DNS setup.
Clearing Corrupted Cache and App Data
Stale or broken cache files can throw Chrome into a loop where it keeps failing to resolve destinations it should easily find. Head into Chrome settings, open up Privacy and Security > Clear browsing data, and dump your cached images and files. Once that's done, fully quit and restart the browser to make sure all cached routing tables get a fresh start.
If this is happening in your CI pipeline, drop those --no-sandbox and --disable-dev-shm-usage flags into your config right away. For local Cypress runs, swap any remaining chromeWebSecurity: false flags for cy.origin(). And if it's just regular browsing giving you grief, a quick extension prune and cache clear usually gets you back on track.
Quick answers
Frequently asked questions
What does chrome-error://chromewebdata/ mean?
It is Chrome's internal error page that appears when the browser attempts to load a URL but receives no valid response. In testing environments it usually means the server was not ready, a cross-origin policy blocked the connection, or a Docker container ran out of shared memory.
How to fix chrome-error://chromewebdata/ in Cypress?
For cross-origin issues, replace chromeWebSecurity: false with the cy.origin() command. For server startup timing issues, use the wait-on package to hold Cypress until your local server is accepting connections. In Docker/CI, add the --no-sandbox and --disable-dev-shm-usage Chrome flags.
Why is chromeWebSecurity: false deprecated in Cypress?
It was a workaround that fails when the target server enforces X-Frame-Options headers, leaves the test environment insecure, and does not reflect real user conditions. The cy.origin() command is the official replacement for handling cross-origin navigation.
How to fix chrome-error://chromewebdata/ in Docker or GitHub Actions?
Add --no-sandbox and --disable-dev-shm-usage to Chrome's launch arguments in your Cypress config. These flags are required in headless containerized environments because Docker limits /dev/shm memory, which crashes Chrome without them.
Can extensions cause the chromewebdata error?
Yes. VPN extensions and aggressive ad blockers can intercept browser-level network requests and break Chrome's internal routing. Disabling all extensions and retesting is one of the first steps for regular browsing errors.
Something wrong or out of date?
Tools change fast. Tell the editor what no longer works.