# @sparticuz/chromium

> Chromium for Serverless Platforms

Source: https://talira.ai/catalog/sparticuz-chromium-6dg9tc7a
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library
- Categories: [developer tools / browser automation / browser binaries](https://talira.ai/categories/developer-tools/browser-automation/browser-binaries), [languages / javascript](https://talira.ai/categories/languages/javascript)
- Platforms: linux[^1]
- Licence: MIT[^2]
- Pricing: Free and open source[^2]
- Free tier: yes[^2]
- Self-hostable: yes[^1]
- Creator: Kyle McNally (Sparticuz)

@sparticuz/chromium is a Brotli-compressed build of Chromium's headless shell for serverless platforms such as [AWS Lambda](https://talira.ai/catalog/aws-lambda-13y26fra.md), with the code that decompresses it into /tmp and a set of launch arguments tuned for those environments. It provides only the browser: you drive it with puppeteer-core ([Puppeteer](https://talira.ai/catalog/puppeteer-vbv4zakx.md)) or playwright-core ([Playwright](https://talira.ai/catalog/playwright-r7fvkefh.md)) by passing `chromium.args` and `await chromium.executablePath()` to their launch call. Versions follow Chromium's major versions rather than semver, so you install the one that matches your puppeteer-core. The npm package ships x64 binaries; `@sparticuz/chromium-min` leaves them out so they load from a Lambda layer or a pack hosted on S3, which is also how arm64 works. It succeeds the author's @sparticuz/chrome-aws-lambda, itself a fork of chrome-aws-lambda, and Puppeteer's troubleshooting guide points to it for AWS Lambda.

## Links

- GitHub: https://github.com/Sparticuz/chromium

## Problems it solves

- puppeteer's bundled Chrome pushes my Lambda deployment past the 250 MB unzipped limit
- Chrome won't launch inside Lambda because the runtime is missing the shared libraries it needs
- chrome-aws-lambda is years out of date and doesn't work with current puppeteer-core versions
- take screenshots of web pages from a serverless function
- run Playwright's Chromium inside an AWS Lambda function
- turn HTML into PDFs with headless Chrome inside a Node.js AWS Lambda function
- puppeteer-core on Lambda needs a Chromium binary built for Amazon Linux
- scrape JavaScript-rendered pages from a Lambda function on a schedule
- my Lambda zip is over the 50 MB direct upload limit once a headless browser is in it
- download the headless browser from S3 on cold start instead of bundling it in the function
- share one Chromium build across many Lambda functions as a layer
- run headless Chrome on Graviton arm64 Lambda functions
- print pages to PDF with headless Chromium in a Netlify function
- screenshots from my Lambda show empty boxes for emoji and Chinese text: add fonts to headless Chrome
- Error: The input directory /var/task/bin does not exist after bundling my Lambda with esbuild
- which Chromium version should I use with my puppeteer-core version on Lambda
- deploy headless Chromium with AWS SAM or the Serverless Framework
- use the same headless browser binary from a non-Node language such as C# on Lambda

## Features

- Brotli-compressed Chromium headless shell that decompresses into /tmp at startup
- chromium.args: recommended Chromium flags for serverless environments
- chromium.executablePath(): path to the extracted binary, from the package, a local folder or a remote pack URL
- works with puppeteer-core and playwright-core
- works with all currently supported AWS Lambda Node.js runtimes
- @sparticuz/chromium-min: same code without the binaries, for layers or remote packs
- Lambda layer zips and pack tars for x64 and arm64 in each GitHub release
- ships Open Sans (Latin, Greek, Cyrillic); extra fonts from /opt/fonts, /var/task/fonts or /tmp/fonts
- WebGL through SwiftShader/ANGLE, which setGraphicsMode = false turns off
- Makefile target to build your own Lambda layer
- examples for AWS SAM, the Serverless Framework, Lambda layers and Netlify

## Limitations

- Doesn't run on macOS or Windows: the bundled Chromium is compiled for Linux only, so local development needs a separately installed Chrome or Chromium[^1]
- Doesn't include arm64 binaries in the npm package: arm64 (Graviton) needs @sparticuz/chromium-min with the layer or pack from a GitHub release[^1]
- Doesn't produce tagged (accessible) PDFs: you have to recompile Chromium with a patch and load it through @sparticuz/chromium-min[^1]
- Doesn't support headful mode or Chrome's new headless mode: it's built on headless_shell, with no GUI[^1]

## Trust

Overall: 0.23 out of 1.
Signals: backing 0.20, extensibility 0.00.

- created by Kyle McNally (Sparticuz)

Warnings:

- GitHub activity not fetched yet

## Related

- Works with [Puppeteer](https://talira.ai/catalog/puppeteer-vbv4zakx.md)
- Works with [Playwright](https://talira.ai/catalog/playwright-r7fvkefh.md)
- Works with [AWS Lambda](https://talira.ai/catalog/aws-lambda-13y26fra.md)

## Sources

[^1]: https://github.com/Sparticuz/chromium (checked 20 Nov 2026)
[^2]: https://github.com/Sparticuz/chromium/blob/master/LICENSE (checked 20 Nov 2026)
