How to Fix Playwright “Executable doesn’t exist” Error
A Playwright test fails with browserType.launch: Executable doesn't exist at ... when the browser build for the installed Playwright version is not in the expected location. Running npx playwright install to install the browsers fixes it. The error appears right after you install Playwright with npm install, and also after you upgrade @playwright/test. It is also common when you start running E2E tests in CI (such as GitHub Actions) or update dependencies.
I reproduced this error under three conditions in my test environment, and confirmed that the tests pass after installing the browsers.
My test environment was Ubuntu 24.04, Node.js 22.23.4, and @playwright/test 1.63.0 (1.65.1 for the upgrade check). I wrote the tests in TypeScript and only tried Chromium. I did not try Windows, macOS, Firefox, WebKit, or Playwright in other languages such as Python. The test environment could not reach the official browser download host, so I placed browsers of the same revisions on a local server in the same layout as the download host, pointed the environment variable PLAYWRIGHT_DOWNLOAD_HOST at that server, and installed them with npx playwright install. I did not have the browsers for 1.65.1 locally, so I did not verify that the tests pass after upgrading to 1.65.1 and installing its browsers.
- 1. Output when running tests without installing browsers
- 2. npm install alone does not install browsers
- 3. Installing browsers with npx playwright install
- 4. The error appears again after upgrading @playwright/test
- 5. Installing with –only-shell and running with –headed
- 6. On Linux, system libraries are also required
Output when running tests without installing browsers
In a new directory, I ran npm i -D @playwright/test@1.63.0 and wrote one test that only checks a heading.
// tests/hello.spec.ts
import { test, expect } from '@playwright/test';
test('見出しが表示される', async ({ page }) => {
await page.setContent('<h1>こんにちは</h1>');
await expect(page.getByRole('heading')).toHaveText('こんにちは');
});
The projects in the config file had only one entry, Chromium (devices['Desktop Chrome']). With this setup, npx playwright test failed in 2ms (exit code 1). I replaced only the home directory path with ~ (the other output in this article is the same).
✘ 1 [chromium] › tests/hello.spec.ts:3:1 › 見出しが表示される (2ms)
1) [chromium] › tests/hello.spec.ts:3:1 › 見出しが表示される ──────────────────────────────────────────────
Error: browserType.launch: Executable doesn't exist at ~/.cache/ms-playwright/chromium_headless_shell-1243/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 ║
╚════════════════════════════════════════════════════════════╝
The path after Executable doesn't exist at is the browser executable that Playwright tried to launch. The box below says, "Looks like Playwright was just installed or updated. Please run the following command to download new browsers: npx playwright install."
npm install alone does not install browsers
I ran ls ~/.cache/ms-playwright before and after npm i -D @playwright/test@1.63.0, and both times it printed No such file or directory. npm installs only the package used to run tests, not the browsers.
The official browsers documentation says that each Playwright version needs a specific browser version, and that you install it with the Playwright CLI. The install location is ~/.cache/ms-playwright on Linux, ~/Library/Caches/ms-playwright on macOS, and %USERPROFILE%\AppData\Local\ms-playwright on Windows (the section on browser binary locations).
To see what would be installed where, add --dry-run. It shows the plan without installing anything.
$ npx playwright install --dry-run chromium
Chrome for Testing 153.0.8010.12 (playwright chromium v1243)
Install location: ~/.cache/ms-playwright/chromium-1243
Download url: https://cdn.playwright.dev/builds/cft/153.0.8010.12/linux64/chrome-linux64.zip
FFmpeg (playwright ffmpeg v1011)
Install location: ~/.cache/ms-playwright/ffmpeg-1011
(取得先の表示は省略)
Chrome Headless Shell 153.0.8010.12 (playwright chromium-headless-shell v1243)
Install location: ~/.cache/ms-playwright/chromium_headless_shell-1243
Download url: https://cdn.playwright.dev/builds/cft/153.0.8010.12/linux64/chrome-headless-shell-linux64.zip
The chromium_headless_shell-1243 from the error message is listed here. For 1.63.0, headless tests use Chrome Headless Shell revision 1243.
Installing browsers with npx playwright install
I ran npx playwright install chromium, and the three items above were installed into ~/.cache/ms-playwright.
$ ls ~/.cache/ms-playwright
chromium-1243
chromium_headless_shell-1243
ffmpeg-1011
On disk, chromium-1243 was 393M, chromium_headless_shell-1243 was 261M, and ffmpeg-1011 was 4.9M. After that, npx playwright test passed.
✓ 1 [chromium] › tests/hello.spec.ts:3:1 › 見出しが表示される (102ms)
1 passed (598ms)
I ran npx playwright install chromium again (with --no-progress to hide the progress display). It finished with no output and did not download the browsers that were already installed.
Running npx playwright install without chromium installs all the default browsers. With --dry-run, I confirmed five items: Chromium, Chrome Headless Shell, Firefox, WebKit, and FFmpeg. If your tests use only Chromium, adding chromium as above downloads only the Chromium files.
Executable doesn't exist is a problem with the browser being missing, not with the test code. Run npx playwright install once before running the tests (you may add the browser names you need).
The error appears again after upgrading @playwright/test
From a state where the browsers were installed and the tests passed, I upgraded with npm i -D @playwright/test@1.65.1. The same test failed again.
Error: browserType.launch: Executable doesn't exist at ~/.cache/ms-playwright/chromium_headless_shell-1255/chrome-headless-shell-linux64/chrome-headless-shell
This time it looks for chromium_headless_shell-1255. Running npx playwright install --dry-run chromium with 1.65.1 showed that both Chrome for Testing and Chrome Headless Shell are version 159.0.8154.6 (revision 1255). ~/.cache/ms-playwright only has revision 1243 from 1.63.0, so there is nothing to launch.

When I downgraded @playwright/test back to 1.63.0, the tests passed again with the installed revision 1243. This means the package decides which revision each version uses. The official guide on regularly updating Playwright also says to run npx playwright install right after updating Playwright.
npm install -D @playwright/test@latest
npx playwright install
When the Playwright version changes, the browser revision it looks for also changes. Keep this in mind if you cache browsers in CI. The official CI guide does not recommend caching browsers, and if you do cache them, it says to use a hash of the Playwright version as the cache key.
Installing with –only-shell and running with –headed
Adding --only-shell installs only the headless Chrome Headless Shell. I deleted ~/.cache/ms-playwright, then ran npx playwright install --only-shell chromium. Two items were installed.
$ ls ~/.cache/ms-playwright
chromium_headless_shell-1243
ffmpeg-1011
A normal npx playwright test passed. However, npx playwright test --headed, which shows the browser window, failed with the same kind of error, but with a different path.
Error: browserType.launch: Executable doesn't exist at ~/.cache/ms-playwright/chromium-1243/chrome-linux64/chrome
When showing a window, Playwright uses the regular Chromium (chromium-1243), not Chrome Headless Shell. The official Chrome Headless Shell section presents --only-shell as an option for running tests only in headless mode, without specifying channel, as in CI. If you run tests with --headed on your own PC, install without --only-shell.
On Linux, system libraries are also required
Even when the browsers are installed, a browser on Linux cannot start if the system libraries it needs are missing. The official section on installing system dependencies introduces npx playwright install-deps for CI and similar setups, and npx playwright install --with-deps chromium, which installs the browser together with its dependencies. In my test environment, npx playwright install-deps --dry-run chromium reported All system dependencies are installed., so the libraries were already present.
The example in the CI guide also runs npx playwright install --with-deps before the tests. If you put this command right after npm ci in your CI configuration, the browsers installed match the Playwright version in use at that point.
If you install browsers from a source other than the official download host, such as an internal mirror, you can change the source with the environment variable PLAYWRIGHT_DOWNLOAD_HOST (official documentation on downloading from an artifact repository).





