Puppeteer launch fails because /usr/bin/chromium-browser is only a snap wrapper
Fix it fast
Most common cause, 1 of 3The launch code hard-codes executablePath: '/usr/bin/chromium-browser'
Remove executablePath from the launch call and let Puppeteer start the Chrome for Testing build it ships with; its docs say it only tests and guarantees those binaries.
// before: puppeteer.launch({ executablePath: '/usr/bin/chromium-browser' })
const browser = await puppeteer.launch();
# shell, as the user that runs the script
npx puppeteer browsers install chromeShort answer
Failed to launch the browser process with Command '/usr/bin/chromium-browser' requires the chromium snap to be installed means Puppeteer was told to run Ubuntu's chromium-browser, which is only a transitional wrapper for the Chromium snap. Where snapd is not running (WSL, chroots, containers) the snap never arrived. Drop that path and use Puppeteer's own Chrome for Testing. Ubuntu 20.04 to 24.04.
Which cause do you have?
Find where the chromium-browser path comes from and what that file really is. A hit in your code is cause 1, a value in the environment variable is cause 2, and a Dockerfile that installs the package is cause 3. A dpkg version containing snap confirms the file is the transitional wrapper.
grep -rn "chromium-browser" --include=*.js --include=*.mjs --include=*.ts --include=Dockerfile . | grep -v node_modules
echo "PUPPETEER_EXECUTABLE_PATH=$PUPPETEER_EXECUTABLE_PATH"
dpkg -s chromium-browser | grep '^Version'Then find the line you see in this list and open its fix:
- 1The launch code hard-codes executablePath: '/usr/bin/chromium-browser'
grep finds executablePath: '/usr/bin/chromium-browser' in your script, and dpkg shows a version like 2:1snap1-0ubuntu2 - 2PUPPETEER_EXECUTABLE_PATH still points at the wrapper
Your code passes no executablePath, yet the echo prints PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser - 3An Ubuntu-based Docker image installs chromium-browser with apt
The Dockerfile starts FROM ubuntu (or an image built on it) and runs apt-get install chromium-browser
What does the error look like?
Error: Failed to launch the browser process!Command '/usr/bin/chromium-browser' requires the chromium snap to be installed.
Cause 1 of 3
The launch code hard-codes executablePath: '/usr/bin/chromium-browser'
You seegrep finds executablePath: '/usr/bin/chromium-browser' in your script, and dpkg shows a version like 2:1snap1-0ubuntu2
Check
Puppeteer reports Failed to launch the browser process and prints the wrapper's own message, because on Ubuntu the chromium-browser package is a transitional package that only installs the Chromium snap. Its changelog says the package no longer tries to install the snap where snapd is not running, naming chroots and WSL, and a Canonical developer on the same bug states that the user must then install the snap by hand. So the file exists but has no browser behind it.
snap list chromiumFix
Remove executablePath from the launch call and let Puppeteer start the Chrome for Testing build it ships with; its docs say it only tests and guarantees those binaries. Download that browser once for the current user.
// before: puppeteer.launch({ executablePath: '/usr/bin/chromium-browser' })
const browser = await puppeteer.launch();
# shell, as the user that runs the script
npx puppeteer browsers install chromeVerify
Chrome for Testing sits in the default cache folder, and the script now opens pages.
ls ~/.cache/puppeteer
node scrape.jsConfirmed by bugs.launchpad.net
Cause 2 of 3
PUPPETEER_EXECUTABLE_PATH still points at the wrapper
You seeYour code passes no executablePath, yet the echo prints PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser
Check
Puppeteer reads the browser path from the PUPPETEER_EXECUTABLE_PATH variable, and its configuration guide says environment variables always override configuration file options. Alpine instructions set this variable to /usr/bin/chromium-browser, where Alpine has a real Chromium package; copied into a shell profile, a .env file or a CI setting on Ubuntu, it sends every launch to the snap wrapper.
grep -rn "PUPPETEER_EXECUTABLE_PATH" ~/.bashrc ~/.profile ~/.zshrc .env* 2>/dev/nullFix
Delete the variable where it is set, open a new shell, and install Puppeteer's browser so the default path has something to launch.
unset PUPPETEER_EXECUTABLE_PATH
# remove the export line from the file grep found, then:
npx puppeteer browsers install chromeVerify
A fresh shell prints an empty value, and the launch succeeds.
echo "PUPPETEER_EXECUTABLE_PATH=$PUPPETEER_EXECUTABLE_PATH"
node scrape.jsConfirmed by pptr.dev
Cause 3 of 3
An Ubuntu-based Docker image installs chromium-browser with apt
You seeThe Dockerfile starts FROM ubuntu (or an image built on it) and runs apt-get install chromium-browser
Check
An image build is one more place where snapd is not running, so the same transitional package lands without the snap and the container ships only the wrapper script. Puppeteer's postinstall download may be missing too, because some package managers now block dependency install scripts, which Puppeteer's troubleshooting guide lists as a reason the browser never arrives.
docker run --rm my-scraper-image dpkg -s chromium-browser | grep '^Version'Fix
Drop the apt package and install Chrome for Testing with its Ubuntu system libraries in the build. The --install-deps flag works on Ubuntu and Debian and needs root, so run it before any USER line in the Dockerfile. If the app later runs as another user, put the browser in a shared folder with PUPPETEER_CACHE_DIR.
FROM ubuntu:24.04
# ... install Node.js and copy the app ...
ENV PUPPETEER_CACHE_DIR=/opt/puppeteer
RUN npm ci && npx puppeteer browsers install chrome --install-depsVerify
The rebuilt image has the browser in the shared cache folder and no chromium-browser package.
docker run --rm my-scraper-image ls /opt/puppeteerConfirmed by pptr.dev
How do I stop it coming back?
- Leave executablePath unset unless you manage the browser yourself; Puppeteer is released against one Chrome for Testing version.
- Add an explicit npx puppeteer browsers install chrome step to CI and Dockerfiles instead of relying on the postinstall download.
- Keep Puppeteer settings in a .puppeteerrc.cjs file in the repository, not in shell profiles, so a stale browser path shows up in code review.
Sources
- Launchpad bug 1882232: chromium-browser snap skipped where snapd is not running
- Ubuntu packages: chromium-browser in noble (transitional)
- Puppeteer: Configuration (executablePath, cacheDirectory)
- Puppeteer: configuration guide
- Puppeteer: browsers CLI (install, --install-deps)
- Puppeteer: troubleshooting
- Docker: running containers (default user is root)
How was this page made?
I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.