Puppeteer is a JavaScript library that provides a high-level API for controlling Chrome or Firefox through the DevTools Protocol or WebDriver BiDi. Puppeteer runs in headless mode (no visible UI) by default, but it can be configured to run in a visible ("headed") browser.