Examples & Use cases

Official examples

The Puppeteer repository includes a small number of examples maintained by the Puppeteer team.

Follow the instructions in the README to run the examples, covering use cases like creating PDFs from websites, creating screenshots or intercepting requests.

Example suite

Find a set of unstructured examples in Puppeteer’s dedicated example repository.

This suite is a collection of examples that has been growing over time and covers various use cases like forwarding events from your Puppeteer process to the browser, interacting with elements and running CDP commands.

Other projects, articles and demos

See the following list for use cases and examples from categories like Rendering, Web scraping and Testing.

Rendering and web scraping

Testing