microsoft/playwright · error · Error

Executable doesn't exist at ${e} ${wrapInASCIIBox(prettyMess

Error message

Executable doesn't exist at ${e}
${wrapInASCIIBox(prettyMessage, 1)}

What it means

Thrown by executablePathOrDie when the expected binary path is known for the platform but the file is not present/cannot be accessed. Playwright formats a boxed, human-readable message telling you exactly which command to run to download the missing browsers, including special guidance for ffmpeg and for outdated Docker images.

Source

Thrown at packages/playwright-core/src/server/registry/index.ts:555

            `Video rendering requires ffmpeg binary.`,
            `Downloading it will not affect any of the system-wide settings.`,
            `Please run the following command:`,
            ``,
            `    ${buildPlaywrightCLICommand(sdkLanguage, 'install ffmpeg')}`,
            ``,
            `<3 Playwright Team`,
          ].join('\n');
        } else {
          prettyMessage = [
            `Looks like Playwright was just installed or updated.`,
            `Please run the following command to download new browser${installByDefault ? 's' : ''}:`,
            ``,
            `    ${installCommand}`,
            ``,
            `<3 Playwright Team`,
          ].join('\n');
        }
        throw new Error(`Executable doesn't exist at ${e}\n${wrapInASCIIBox(prettyMessage, 1)}`);
      }
      return e;
    };
    this._executables = [];

    const chromium = descriptors.find(d => d.name === 'chromium')!;
    const chromiumExecutable = findExecutablePath(chromium.dir, 'chromium');
    this._executables.push({
      name: 'chromium',
      browserName: 'chromium',
      directory: chromium.dir,
      executablePath: () => chromiumExecutable,
      executablePathOrDie: (sdkLanguage: string) => executablePathOrDie('chromium', chromiumExecutable, chromium.installByDefault, sdkLanguage),
      installType: chromium.installByDefault ? 'download-by-default' : 'download-on-demand',
      _validateHostRequirements: (sdkLanguage: string) => this._validateHostRequirements(sdkLanguage, chromium.dir, ['chrome-linux'], [], ['chrome-win']),
      downloadURLs: this._downloadURLs(chromium),
      title: chromium.title,
      revision: chromium.revision,

View on GitHub (pinned to c8fc3bf8d3)

Solutions

  1. Run the install command printed in the error (e.g. `npx playwright install`), which downloads the required browsers.
  2. If using the official Docker image, update it to the tag matching your playwright version.
  3. Verify PLAYWRIGHT_BROWSERS_PATH is set consistently across install and run, or unset it to use the default cache directory.

Example fix

# error tells you the exact command; run it
npx playwright install
# keep path consistent in CI
export PLAYWRIGHT_BROWSERS_PATH=/opt/pw-browsers
npx playwright install
Defensive patterns

Strategy: validation

Validate before calling

import { canAccessFile } from '@_playwright'; // or fs.accessSync
if (!fs.existsSync(exePath))
  throw new Error('browsers not installed; run `npx playwright install`');

Try / catch

try {
  await browser.launch();
} catch (e) {
  if (/Executable doesn't exist at/.test(e.message)) {
    await run('npx', ['playwright', 'install']);
    await browser.launch(); // one retry after install
  } else throw e;
}

Prevention

When it happens

Trigger: Playwright was just installed/upgraded but `playwright install` was not run; a CI cache miss wiped the browsers directory; PLAYWRIGHT_BROWSERS_PATH points to an empty or wrong location; using an outdated Docker image after a driver upgrade.

Common situations: Fresh `npm install` in CI without the browser download step; Docker image version mismatch with the installed playwright package; browsers directory deleted to save space; misconfigured PLAYWRIGHT_BROWSERS_PATH.

Related errors


AI-assisted analysis of microsoft/playwright@c8fc3bf8d3 (2026-08-12). Data as JSON: /api/errors/7592a3717e0bb51e. Report an issue: GitHub.