Skip to content
Playwright · error message

Playwright: Executable doesn't exist - please run npx playwright install

ConfigurationInstallation & environment

Last verified

The exact message
Error: browserType.launch: Executable doesn't exist at /home/user/.cache/ms-playwright/chromium_headless_shell-1200/chrome-headless-shell-linux64/chrome-headless-shell ╔═════════════════════════════════════════════════════════════════════════╗ ║ Looks like Playwright was just installed or updated. ║ ║ Please run the following command to download new browsers: ║ ║ ║ ║ npx playwright install ║ ║ ║ ║ <3 Playwright Team ║ ╚═════════════════════════════════════════════════════════════════════════╝

What it means

Playwright does not use the Chrome, Firefox or Safari installed on your machine by default. Each Playwright release is pinned to specific browser builds that it downloads into a cache folder (~/.cache/ms-playwright on Linux, ~/Library/Caches/ms-playwright on macOS, %USERPROFILE%\AppData\Local\ms-playwright on Windows). This error means the exact build your installed Playwright version expects is not in that folder.

The build number in the path (for example chromium_headless_shell-1200) is tied to the Playwright version, so upgrading the npm or pip package without re-running the install step reliably produces this error. The boxed message prints the right command for your language: npx playwright install for Node.js, playwright install for Python.

What is not wrong: your code, and usually not your system Chrome. Installing Google Chrome does not satisfy this check unless you launch with channel: 'chrome'.

What it looks like

# Node.js
npm install -D @playwright/test@latest
npx playwright install --with-deps chromium

# Python
pip install --upgrade playwright
python -m playwright install --with-deps chromium

# GitHub Actions step
- run: npx playwright install --with-deps

Why it happens

  • The Playwright package was installed or upgraded but the browser download step was never run.
  • CI caches node_modules or the pip environment but not the ms-playwright browser folder, or caches a stale one.
  • PLAYWRIGHT_BROWSERS_PATH points at a different folder at install time than at run time.
  • Two Playwright versions are present (for example @playwright/test and playwright, or a global and local install) and the browsers match only one of them.
  • The Docker image tag does not match the Playwright version in your lockfile.

How to fix it

  1. Run the command printed in the box: npx playwright install (Node.js) or playwright install / python -m playwright install (Python).
  2. To install only what you use: npx playwright install chromium; add --with-deps on Linux to also install system libraries.
  3. Check for version drift with npm ls playwright @playwright/test or pip show playwright, and align them.
  4. In CI, run the install step after dependency installation on every job, or key the browser cache on the Playwright version.
  5. In Docker, use mcr.microsoft.com/playwright:v-noble so browsers and library match.

How to stop it recurring

Make browser installation part of the same step that installs the Playwright package, for example a postinstall script or a CI step that always runs after npm ci. Pin the Playwright version in your lockfile and match the Docker image tag to it. If you cache browsers, key the cache on the Playwright version so an upgrade invalidates it automatically.

Official documentation: playwright.dev/docs/browsers#install-browsers. See all Playwright error messages.

Related errors

Definitions

Quick answers

What does "Executable doesn't exist - please run npx playwright install" mean in Playwright?

Playwright does not use the Chrome, Firefox or Safari installed on your machine by default. Each Playwright release is pinned to specific browser builds that it downloads into a cache folder ( ~/.cache/ms-playwright on Linux, ~/Library/Caches/ms-playwright on macOS, %USERPROFILE%\AppData\Local\ms-playwright on Windows). This error means the exact build your installed Playwright version expects is not in that folder.

How do I fix "Executable doesn't exist - please run npx playwright install"?

1. Run the command printed in the box: npx playwright install (Node.js) or playwright install / python -m playwright install (Python). 2. To install only what you use: npx playwright install chromium; add --with-deps on Linux to also install system libraries. 3. Check for version drift with npm ls playwright @playwright/test or pip show playwright, and align them. 4. In CI, run the install step after dependency installation on every job, or key the browser cache on the Playwright version. 5. In Docker, use mcr.microsoft.com/playwright:v -noble so browsers and library match.

Run browser automation you can watch and take over

Autonoly runs each job in a real cloud Chromium browser driven by Playwright. Timeouts and detached elements still happen; the difference is that you can watch the run live, see the step that failed, and take control of the browser to finish it.

Also see Live browser control.