Skip to main content
Tutorial

Self-Hosted Rust Scraping: One Binary, Full Control

Self-host a Rust web scraper as one static binary: full control, low footprint, AGPL-3.0, and a Firecrawl-compatible API. Setup, trade-offs, and when to use it.

fastcrw
By RecepNovember 26, 202610 min read

By the fastCRW team · Footprint, benchmark, and pricing claims verified 2026-05-18 · Verify independently before relying on it.

Disclosure: We build fastCRW. This guide is vendor-authored, so weight it accordingly — but every number traces to a published benchmark or the repo, and the honest gaps are stated up front so you can decide on facts, not marketing.

Why a Rust scraping engine for self-hosting

If you are searching for a self-hosted Rust web scraping engine, you usually want three things at once: control over where your data goes, a footprint small enough to run anywhere, and an engine that does not turn into a platform-team project the moment you deploy it. fastCRW is built for exactly that profile — a single static Rust binary you run inside your own network, under AGPL-3.0, speaking a drop-in Firecrawl-compatible REST API.

Memory safety and a small static footprint

Rust gives you memory safety without a garbage collector, which matters for a long-running service that holds connections and parses untrusted HTML all day. The practical payoff is the footprint: the fastCRW engine ships as a single ~8 MB Docker image (the binary itself is ~6 MB), needing one container, versus Firecrawl's ~2–3 GB across 5 containers (README "Structural footprint", framed as structural facts, not benchmark claims). That is the difference between "self-host is one docker run" and "self-host is a multi-service stack with a queue and a browser fleet."

One binary, no Redis or Node to operate

The engine requires no Redis, no Node.js, and no separate browser service to start. There is one process to supervise, one log stream to read, one thing to restart. For a team that wants web data without inheriting a distributed system, that single-process topology is the feature — see the single-binary infrastructure explainer for the general case.

AGPL-3.0: run it forever, no license fee

Self-hosting the AGPL-3.0 engine is free — you pay only for your own server. There is no per-seat license, no metered call when you run it yourself, and the source lives at github.com/fastcrw/crw so you can fork it, patch it, and keep running your fork indefinitely. AGPL's copyleft trigger only fires if you modify the engine and offer that modified version to third parties over a network; internal pipelines and unmodified deployments are unaffected.

Setting up the self-hosted engine

Run the single binary or Docker Compose

The fastest path is Docker Compose, which brings up the engine plus the optional SearXNG sidecar that powers /v1/search. The default Compose ships the lightpanda renderer; chrome is opt-in (and pulls the footprint up to roughly a 500 MB image plus ~1 GB resident when enabled). A minimal run looks like this:

  • Clone the repo from github.com/fastcrw/crw and start the stack with Docker Compose, or run the static binary directly on a host with no Docker at all.
  • The engine binds an HTTP port and exposes the REST surface immediately — there is no migration step and no datastore to provision because the engine is stateless per request.
  • For a deeper walkthrough, see self-hosting fastCRW with Docker Compose.

Renderer selection: auto, http, lightpanda, chrome

fastCRW exposes four renderers. auto (the default) picks one per URL and falls back chrome → lightpanda → http when a lighter renderer fails to produce usable content. http is a plain fetch for static pages; lightpanda is a lightweight JavaScript-capable renderer; chrome is the full headless browser for the hardest pages. Credit-wise on the managed cloud, every renderer (http, lightpanda, chrome) costs 1 credit per scrape with no JS-rendering surcharge — and when you self-host, the renderer choice costs you nothing but compute.

Authentication, health checks, and base URL

The engine exposes GET /health with no auth for liveness and readiness probes — wire it into your orchestrator. Everything else lives under /v1. Because the API is Firecrawl-compatible, your "base URL" is the one knob your clients need: point the official Firecrawl SDK at your self-hosted engine by swapping api_url, and existing code keeps working.

Using the Firecrawl-compatible API

Scrape, crawl, map, and search endpoints

The open-core REST surface covers the four operations most pipelines need:

EndpointPurpose
POST /v1/scrapeScrape one URL; LLM extraction via formats: ["json"] + jsonSchema
POST /v1/crawlStart an async BFS crawl — returns a job ID (poll GET /v1/crawl/:id)
POST /v1/mapDiscover all URLs on a site
POST /v1/searchWeb search via the SearXNG sidecar, optional content scraping

Crawl accepts maxDepth (cap 10) and maxPages (cap 1000), with limit and max_pages as accepted aliases. There is no /v1/batch/scrape endpoint — for many URLs you iterate /v1/scrape concurrently or use /v1/crawl.

JSON-schema extraction with formats: ['json']

Structured extraction is built into /v1/scrape: pass formats: ["json"] with a jsonSchema and the engine returns typed fields instead of raw markdown. On the managed cloud there is a /v1/extract convenience wrapper (single-URL; the 1-credit scrape plus the LLM token cost, billed as usage-metered LLM credits) over the same path, but self-hosters call /v1/scrape + jsonSchema directly and get the same result. See structured extraction with JSON schema for worked examples.

Calling it from the Python SDK (crw) or curl

The Python SDK package crw (PyPI) ships a CrwClient() that runs a self-contained local engine — handy when you want the engine embedded in a Python process rather than as a separate service. Or hit the REST surface from curl, any HTTP client, or the official Firecrawl SDK with a swapped base URL. If you are coming from a Python scraping stack, the Python quickstart covers the first calls, and web scraping in Rust covers the lower-level Rust angle.

Full control means full responsibility

Self-hosting hands you the keys, which also means you own the parts a managed cloud would otherwise handle. Be honest with yourself about these before you commit.

Self-host has no proxy / anti-bot — you supply your own

fastCRW has no Fire-engine-style anti-bot layer, and the self-hosted engine ships no proxy pool of its own (on the managed cloud, paid-plan traffic is proxied for you). For hostile, hardened targets that actively fight scrapers, the honest answer is a dedicated proxy/anti-bot vendor such as Bright Data or Oxylabs in front of the engine — fastCRW will not out-muscle them on those sites, and we are not going to pretend otherwise.

Stateless engine: orchestrate scheduling yourself

The engine is stateless per request — there is no persistent session or built-in scheduler. Recurring crawls, retries, and audit logging are yours to orchestrate (a cron job, a queue, or your existing pipeline). The Rust-vs-Python architecture comparison digs into why a stateless core is a deliberate trade for operational simplicity.

LLM extraction is a managed, paid-plan feature

LLM-backed JSON extraction is a managed feature available on paid plans, running on a managed LLM; the FREE plan has no LLM features. (The managed /v1/search answer synthesis is a separate managed LLM feature on the same paid plans.) There is also no screenshot output — a request for formats: ["screenshot"] returns HTTP 422 — and no /v1/agent or /v1/deep-research. Plan around these rather than discovering them in production.

Self-host vs the managed cloud

$0 per 1,000 scrapes self-hosted

The cost story is the clearest reason to self-host: $0 per 1,000 scrapes when you run the AGPL-3.0 engine yourself (you pay only your server), versus Firecrawl hosted at $0.83–5.33 per 1,000 scrapes across its tiers (competitor-prices.lock.md, verified 2026-05-18). On accuracy, the engine is not a toy: it scored the highest truth-recall of the three tools tested — 63.74% of 819 labeled URLs — alongside 91.8% scrape-success (of reachable URLs) with 0 thrown errors, and a p50 of 1914 ms that beats Firecrawl's 2305 ms (diagnose_3way.py, Firecrawl's public dataset, 2026-05-08). In fast mode, p90 is 4348 ms — the lowest of the three — so both accuracy and tail latency favor fastCRW. We publish the full p50/p90 split rather than a single average — see /benchmarks.

When to flip to the cloud on the same API

Because self-host and managed run the same Firecrawl-compatible engine, the decision is reversible. Self-host when privacy, a hard cost ceiling, or high volume dominates. Flip to the managed cloud — a base-URL swap, no rewrite — when you want managed proxies, zero-ops, or burst scale you do not want to operate yourself. Compare the live tiers at /pricing, and read single-binary infrastructure if footprint is the deciding factor.

Sources

  • fastCRW repo, endpoint table, renderer selection, and structural footprint: github.com/fastcrw/crw
  • Scrape benchmark (truth-recall 63.74% of 819 labeled URLs — highest; p50 1914 ms; fast-mode p90 4348 ms — lowest of three): bench/server-runs/RESULT_3WAY_1000_FULL.md via diagnose_3way.py, 2026-05-08
  • Self-host vs hosted cost ($0 vs $0.83–5.33 per 1,000 scrapes): marketing/competitor-prices.lock.md, verified 2026-05-18 · live tiers at /pricing

Related: Web scraping in Rust · Self-host fastCRW with Docker Compose · Rust vs Python scraper architecture · Single-binary infrastructure

FAQ

Frequently asked questions

How do I self-host a Rust web scraper?
Clone the fastCRW repo from github.com/fastcrw/crw and start it with Docker Compose, or run the static binary directly on any host. The engine exposes a Firecrawl-compatible REST API under /v1 immediately — no datastore to provision and no migration step, because it is stateless per request. Point any Firecrawl SDK at your instance by swapping the base URL.
Is the fastCRW engine really a single binary?
Yes. The engine is a single static Rust binary — roughly a 6 MB binary in an ~8 MB Docker image, needing one container, with no Redis or Node.js. The README frames this as a structural fact versus Firecrawl's ~2–3 GB across 5 containers. The optional chrome renderer pulls the footprint up to about a 500 MB image plus ~1 GB resident when you enable it.
Does the self-hosted Rust engine support JavaScript rendering?
Yes. It offers four renderers: http (plain fetch), lightpanda (lightweight JS rendering, the Docker Compose default), chrome (full headless browser, opt-in), and auto, which selects per URL and falls back chrome → lightpanda → http. When self-hosting, renderer choice costs only compute.
What does self-hosting a Rust scraper cost?
$0 per 1,000 scrapes — the AGPL-3.0 engine is free to self-host and you pay only for your own server. There is no per-call meter and no license fee. For comparison, Firecrawl hosted runs $0.83–5.33 per 1,000 scrapes across its tiers (competitor-prices.lock.md, verified 2026-05-18).
What can't the self-hosted engine do compared to the managed cloud?
The self-hosted engine has no built-in anti-bot or residential proxy pool (use Bright Data or Oxylabs for hostile targets), is stateless so you orchestrate scheduling and audit logging yourself, treats LLM-based JSON extraction as a managed, paid-plan feature (the FREE plan has no LLM features), has no screenshot output (HTTP 422), and no /v1/agent or /v1/deep-research. Everything else — scrape, crawl, map, search — runs the same engine as the cloud.

Get Started

Try fastCRW free

Run a live request in the playground — no signup required. Or grab a free API key with 1000 free credits, no credit card.

Continue exploring

More tutorial posts

View category archive