SlimAtlas
About
A MCP server that provides extremely lightweight browser automation capabilities using Lightpanda browser. This server enables LLMs to interact with web pages through browser automation.
Details
- Author
- hasindu-madushan
- Categories
- Web Scraping
Jump to
Setup
Install SlimAtlas in your MCP client (Claude Desktop, Cursor, Windsurf, and others).
Repository: https://github.com/hasindu-madushan/slim-atlas-ai
Follow the installation instructions in the repository README, then restart your MCP client.
An extremely lightweight standalone MCP server for token-efficient browser automation for AI agents, designed to run on servers.
~5x less memory than Chromium. ~25x smaller snapshots than raw HTML.
Built onBun,PuppeteerandLightpanda.
- Browser Automation: Navigate, click, type, fill forms, and evaluate JavaScript
- Lightweight by Default: ~5x less memory than Chromium, ~25x smaller snapshots than raw HTML
- Page Snapshots: Get compact YAML accessibility tree snapshots with unique node IDs for precise element targeting
- LLM-Optimized Context: Snapshots are stripped to semantic essentials, keeping context usage tiny so you can fit more pages and longer sessions into the same window
- Configurable Fallback Browser: Two-level model — lightweight browser first, then escalate toheadful Chrome,BrowserlessorBrowserbasecloud browsers only when the default is bot-detected, crashes, or times out.
- Rate Limiting: Stay under the radar. Enforce a configurable minimum delay between requests to specific domains with wildcard patterns (,.reddit.com) plus optional jitter, so your agent paces itself instead of hammering a site and tripping its bot defenses.
- Proxy Support: Route every request through an HTTP proxy with a singlePROXY_SERVERsetting — applied automatically tobothbrowser layers, so your real IP never touches the target. Supports inline basic auth (http://user:pass@host:port).
- Robust Session Management: Per-session serialization, optional session cap (MAX_SESSIONS), mid-session crash recovery with history replay, and graceful shutdown.
- Session Management: Reuse sessions across multiple operations with unique session IDs
- Cross-Platform: Works on Linux and macOS, with a configurable real-browser fallback when needed
SlimAtlas was benchmarked against Playwright MCP (headless and headful Chromium) usingslim-atlas-bench— 25 real-world sites across 5 categories, 3 runs each (225 total), all running in Docker on localhost.
Setup: Each service runs as an MCP server in its own Docker container. The benchmark harness measures per-tool-call latency (navigate + snapshot) vialangchain-mcp-adapters, and captures container RAM via the Docker stats API. Snapshots are token-estimated at ~4 chars/token (same methodology as the raw HTML baseline).
SlimAtlas trades navigation speed for dramatically lower resource usage. Chromium is faster on page load, but uses5–6x more RAMand produces2–4x more tokensper snapshot — the two costs that dominate at scale in agent workflows.
Browser binary is downloaded automatically on first run.
Fallback browser: Level 1 is always the lightweight browser. Level 2 isFALLBACK_BROWSER— one ofheadful(headful Chrome),browserbase(cloud),browserless(cloud), ornone(default, no fallback). When the default crashes, times out, or is bot-detected, the session switches once to the configured fallback. Chrome is bundled by Puppeteer; Browserbase/Browserless require API credentials (see below).
# Standalone HTTP server (default) bun run src/index.ts --port=8080 # Remote, authenticated MCP_AUTH_TOKEN=s3cret bun run src/index.ts --host=0.0.0.0 --port=8080
SlimAtlas exposes a singleStreamable HTTP/mcpendpoint. Each client gets its own session via themcp-session-idheader;MAX_SESSIONSbounds concurrency. Point your MCP client at it:
{ "mcpServers": { "slimatlas": { "url": "http://localhost:8080/mcp", "transport": "http" } } }
{ "mcpServers": { "slimatlas": { "url": "http://your-host:8080/mcp", "transport": "http", "headers": { "Authorization": "Bearer s3cret" } } } }
Tip: Use--host=0.0.0.0to expose remotely, but always setMCP_AUTH_TOKENwhen doing so. The server speaks plain HTTP only — terminate TLS in front (Caddy/nginx) or the Bearer token travels the network in cleartext.
The image bundles the Lightpanda binary at build time, so the container starts self-contained and never re-downloads:
docker build -t slimatlas . docker run -p 8080:8080 -e MCP_AUTH_TOKEN=s3cret slimatlas # -> http://localhost:8080/mcp
Pin a Lightpanda release for reproducible builds (anylightpanda-io/browsertag — defaultnightly):
docker build --build-arg LIGHTPANDA_VERSION=0.3.3 -t slimatlas:0.3.3 .
Multi-arch is handled automatically — the build detects the container's arch viauname -m(x86_64→lightpanda-x86_64-linux,aarch64→lightpanda-aarch64-linux), so the binary always matches the platform being built.
Apple Silicon (M-series Macs):pass--platform linux/arm64to build/run natively. Without it, Docker Desktop may default toamd64and run the container under Rosetta, which fails to launch the Lightpanda binary (rosetta error: failed to open elf …).
docker build --platform linux/arm64 --build-arg FALLBACK_BROWSER=headful -t slimatlas . docker run --platform linux/arm64 --name slimatlas -p 8080:8080 -e MCP_AUTH_TOKEN=s3cret -e LIGHTPANDA_POOL_SIZE=10 -e CHROME_POOL_SIZE=10 slimatlas
Headful fallback variant.The default image runs Lightpanda only (FALLBACK_BROWSER=none). To enable the headful Chrome fallback (needed only if you setFALLBACK_BROWSER=headfulat runtime), build the headful variant — it adds the Chrome runtime libraries + Xvfb (~150MB) and presetsFALLBACK_BROWSER=headful:
docker build --build-arg LIGHTPANDA_VERSION=0.3.3 FALLBACK_BROWSER=headful -t slimatlas:headful . docker run -p 8080:8080 -e MCP_AUTH_TOKEN=s3cret slimatlas:headful
Xvfb is started lazily inside the container on the first session that escalates to headful Chrome — no entrypoint or manualxvfb-runneeded.
For MCP clients that spawn the server as a subprocess (local, single-client), use stdio transport:
{ "mcpServers": { "slimatlas": { "command": "bun", "args": ["run", "path/to/mcp/src/index.ts"] } } }
{ "mcpServers": { "slimatlas": { "command": "bun", "args": ["run", "path/to/mcp/src/index.ts"] } } }
Tip: SetFALLBACK_BROWSER=noneto use the lightweight browser only and propagate errors honestly. Useheadfulorbrowserbaseto enable a real-browser fallback.
Seedocs/configs.mdfor all environment variables and CLI flags.
Skip the default browser for known-hard domainswithSKIP_LIGHTPANDA_DOMAINS(comma-separated, subdomain-aware). Matched hosts start directly on the fallback browser. RequiresFALLBACK_BROWSER != none(otherwise the list is ignored with a warning).
Polite, anti-detection pacing for your agent.RateLimiterenforces a server-wide minimum delay betweenbrowser_navigatecalls to the domains you list, with optional random jitter so the cadence isn't a fixed, fingerprintable interval. Buckets are keyed per host acrossallsessions (because the target site sees your IP, not your sessions), and patterns support wildcards:
Disabled by default. Enable with a non-empty domain listanda non-zero delay:
# Via CLI flags bun run src/index.ts --rate-limit-domains=.reddit.com,g2.com --rate-limit-min-delay-ms=2000 --rate-limit-jitter-ms=1500 # Or via environment / .env RATE_LIMIT_DOMAINS=.reddit.com,g2.com RATE_LIMIT_MIN_DELAY_MS=2000 RATE_LIMIT_JITTER_MS=1500
Keep your real IP off the target. Set a singlePROXY_SERVERand SlimAtlas routesallHTTP traffic frombothbrowser layers through it — no per-browser wiring needed:
- Lightweight browser (level 1)— forwarded via its native--http-proxyflag.
- Chrome fallback (level 2)— applied via--proxy-serverat launch.
# Via CLI flag bun run src/index.ts --proxy-server=http://host:8080 # Or via environment / .env PROXY_SERVER=http://user:pass@host:8080
Inline basic auth (http://user:pass@host:port) is supported on the lightweight browser layer. For IP-allowlisted proxies (no credentials) it just works on both layers.(Per-page Chrome authentication viapage.authenticateis on the roadmap.)
Every environment variable can also be passed as a lower-case CLI flag in--flag=valueform. CLI flags override environment variables. Unknown flags cause the server to exit at startup. Seedocs/configs.mdfor the full list.
bun run src/index.ts --fallback-browser=headful --lightpanda-pool-size=3 --skip-lightpanda-domains=g2.com --navigate-timeout=60000
To use flags from an MCP client, append them to theargsarray:
{ "mcpServers": { "slimatlas": { "command": "bun", "args": [ "run", "path/to/mcp/src/index.ts", "--fallback-browser=headful", "--skip-lightpanda-domains=g2.com,linkedin.com", "--chrome-pool-size=3" ] } } }
# Example: Navigate, snapshot, and interact with a page # 1. Navigate to a URL (creates a new session automatically) result = mcp.call("browser_navigate", {"url": "https://example.com"}) # Returns: session_id: abc1, result: Navigated to https://example.com. Title: Example Domain # 2. Take a snapshot to see the page structure snapshot = mcp.call("browser_snapshot", {"session_id": "abc1"}) # Returns YAML with node IDs like: 0: {type: div, children: ...} # 3. Click a node by ID (from the snapshot) mcp.call("browser_click", {"session_id": "abc1", "nodeId": 2}) # 4. Type into a search box mcp.call("browser_type", {"session_id": "abc1", "nodeId": 5, "text": "search query"}) # 5. Close the session when done mcp.call("browser_close", {"session_id": "abc1"})
# Run all tests bun test # Run tests in watch mode bun test --watch
- Bun≥1.1
- Linux or macOS (downloads automatically) or Chrome/Chromium (fallback)
Enable AI agents to get structured data from unstructured web with AgentQL.
Web scraping, crawling, and change detection with AI
Official Apify MCP server for AI agents to run Actors, extract website data, and automate web scraping and crawling workflows.
1GB Free Trial, World's Leading Proxy Service Platform, Efficient Data Collection
Discover, extract, and interact with the web - one interface powering automated access across the public internet.
Automate browser interactions in the cloud (e.g. web navigation, data extraction, form filling, and more)
Easy web data access. Simplified retrieval of information from websites and online sources.
Adds powerful web scraping and search capabilities to LLM clients like Cursor and Claude.
Real-time web data, structured for agents
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.



