Skip to content

Install

Requirements

  • Python 3.8 or later
  • pip

Install the package

bash
pip install pyppeteer

On first run pyppeteer automatically downloads a Chromium binary (~150 MB). To do this once upfront rather than at script runtime, run the install helper:

bash
pyppeteer-install

This places the Chromium binary in ~/.pyppeteer/ (or %USERPROFILE%\.pyppeteer\ on Windows). Subsequent runs skip the download.

Virtual environment (best practice)

bash
python -m venv .venv
source .venv/bin/activate        # macOS / Linux
.venv\Scripts\activate           # Windows
pip install pyppeteer
pyppeteer-install

Verify installation

bash
python -c "import pyppeteer; print(pyppeteer.__version__)"

Expected output: 2.0.0

System dependencies (Linux)

On headless Linux servers, Chromium requires shared libraries that may not be present by default. Install them with:

bash
# Debian / Ubuntu
sudo apt-get install -y \
  libglib2.0-0 libnss3 libatk1.0-0 libatk-bridge2.0-0 \
  libcups2 libdrm2 libxkbcommon0 libxcomposite1 libxdamage1 \
  libxfixes3 libxrandr2 libgbm1 libasound2

Notes

  • pyppeteer-install is the bundled CLI entry point; it is safe to re-run.
  • The downloaded Chromium is pinned to a specific revision bundled with the pyppeteer release.
  • On Windows and macOS, Chromium usually works without extra system packages.