Browsers as a Service
Browserless is a cloud-based service for running headless browsers at scale. Browsers as a Service (BaaS) v2 is a direct browser-as-a-service API that you can connect to using standard libraries like Puppeteer or Playwright. BaaS v2 closely mimics running a browser locally, allowing you to use familiar code by simply changing the connection URL to point at Browserless.
BaaS features are best suited for sites where bot detection isn't an issue, especially your own site. For getting past detectors, we'd recommend checking out BrowserQL.
How Browserless Works
Browserless works almost identically to how most libraries and web-drivers work when ran locally. There's no additional software you need to install on your production machines or complicated setup steps. As a matter of fact, the only thing you really need to when using the Browserless' service is merely change where your code references the browser.
Browserless runs browsers in a cloud environment, and exposes most of the Chrome DevTools protocol and the Playwright Protocols to you. On top of exposing these commands, it also:
- Isolates your session from all others.
- Can run concurrent requests without interfering with others.
- Cleans up sessions after 30 seconds.
- Starts a clean copy of a browser for each session.
- Restarts automatically if anything crashes.
- Queues requests if thresholds are met.
- Helps bypass bot detectors.
You can use the hosted service either by connecting an automation library as described below, or by using one of our HTTP APIs.
Getting Started
To use BaaS, you need a unique token, created when you sign-up for a Browserless account:
- Sign up for a Browserless account (free plan available).
- Get your API Key.
Once your worker(s) are ready you should use this token anytime you interact with the service.
You can use this token with most of our integrations by simply appending a ?token=YOUR_API_TOKEN_HERE
as a query-string parameter.
Connecting Libraries
BaaS can be connected to standard libraries like Puppeteer or Playwright. The pages below guide you through an example on how to connect to your preffered choice:
Next Steps
Before exploring all BQL has to offer, learn more about connecting and building an URL for your needs, and all launch parameters available:
BaaS provides a wide range of functionalities that help your web scraping process. To discover all the capabilities Browserless has to offer, start with the following guides:
Advanced Features
Learn about more advanced features that you can take advantage when using BaaS: