Reference
Everything here matches the current release. The README on GitHub has the longer explanations.
Commands
| Command | What it does |
|---|---|
rendercache serve |
Runs the public proxy and the separate admin listener, warms sitemap pages and serves saved copies to crawlers |
rendercache render --url /path |
Renders one page in Chrome now and saves it |
rendercache inspect --url /path |
Prints the saved record for a page without starting Chrome |
rendercache prune --older-than 720h |
Removes old records while the service is stopped |
rendercache health |
Checks the admin health endpoint, using RENDERCACHE_ADMIN_TOKEN |
rendercache version |
Prints the version, commit and platform |
Each command takes --config file.json. Common settings also have flags, such as --origin, --public-url, --listen, --admin-listen, --data-dir, --chrome-path, --ready-selector, --render-timeout, --warm, --sitemap, --snapshots, --snapshot-ttl and --verify-crawlers. Flags override the file. serve reloads the file on SIGHUP (not on Windows) or POST /reload, keeping the same flags and token variables.
Settings
The config file is one JSON object. Unknown keys are rejected. RENDERCACHE_ADMIN_TOKEN and RENDERCACHE_EDGE_TOKEN override the token settings, so secrets can stay out of the file.
| Setting | Default | What it does |
|---|---|---|
origin |
required | Fixed upstream site root |
public_url |
origin | Public root used for URL validation and snapshot identity |
data_dir |
data/snapshots |
Local snapshot and delivery-log directory, one writer process |
snapshot_max_bytes |
1073741824 |
Serialized-record quota; 4096 bytes to 1 TiB |
snapshot_max_files |
10000 |
Record count quota; 1 to 100000 |
max_request_bytes |
16777216 |
Public request-body limit; 1 byte to 256 MiB |
http_concurrency |
32 |
Concurrent public requests (1..256); excess requests return 503 |
edge_token |
empty | Optional public-listener edge key; prefer environment |
delivery_log_max_bytes |
10485760 |
Maximum bytes per log file; 4096 to 1 GiB |
delivery_log_backups |
3 |
Rotated files retained in addition to current file; 1 to 10 |
chrome_path |
auto-detect | Local browser executable |
chrome_no_sandbox |
false |
Explicit browser sandbox opt-out |
render_timeout |
30s |
Hard deadline including capacity wait/startup |
render_settle |
500ms |
Wait after load when no selector is configured |
ready_selector |
empty | CSS selector proving application-specific readiness |
max_html_bytes |
8388608 | Serialized HTML limit, at most 64 MiB |
render_concurrency |
1 | Browser worker slots, range 1–16 |
render_allow_origins |
empty | Additional explicit HTTP(S) asset roots |
snapshot_enabled |
true |
Serve saved responses to eligible bots |
snapshot_ttl |
24h |
HTTP freshness age, minimum 1s |
request_page_limit |
256 | Request-driven page allowance, range 1–10000. A page unrequested for an hour can give up its slot; its snapshot is then deleted |
warm_enabled |
true |
Enable warming while serving |
sitemap_urls |
["/sitemap.xml"] |
Public root sitemap URLs/paths |
warm_interval |
24h |
Snapshot refresh age; minimum 1s |
sitemap_interval |
15m |
Rediscovery schedule; minimum 1s |
warm_retry_base |
5s |
Initial retry delay; minimum 100ms |
warm_retry_max |
5m |
Maximum retry delay, at least base |
warm_queue_size |
128 | Pending job capacity, range 1–10000 |
sitemap_max_bytes |
8388608 | Wire/XML bytes per document, at most 64 MiB |
sitemap_max_urls |
10000 | Maximum discovered pages, at most 100000 |
sitemap_max_documents |
128 | Maximum sitemap documents, at most 1000 |
sitemap_max_depth |
4 | Maximum index depth, root at 0, at most 16 |
sitemap_timeout |
15s |
Timeout for one HTTP fetch |
sitemap_scan_timeout |
2m |
Deadline for complete discovery |
listen |
:8080 |
Public proxy listener |
admin_listen |
127.0.0.1:9090 |
Administration listener |
admin_token |
empty | Optional bearer token on loopback, required elsewhere |
origin_timeout |
30s |
Upstream response-header timeout |
shutdown_timeout |
10s |
Graceful shutdown deadline |
bots |
search, AI and preview crawler patterns, including Google-InspectionTool for Search Console tests | Case-insensitive user-agent substring matches |
bypass_paths |
["/api"] |
Path prefixes that always go to the origin, for example /graphql or /wp-json |
ignore_query_params |
utm_source, utm_medium, utm_campaign, utm_term, utm_content, gclid, fbclid, msclkid | Exact parameter names left out of the snapshot identity, case-insensitive; also applied to purge and compare |
trusted_proxies |
["127.0.0.0/8", "::1/128"] |
Peers whose X-Forwarded-For/Proto/Host are passed to the origin, and whose X-Forwarded-For gives the address checked by verify_crawlers |
verify_crawlers |
false |
A crawler claim must come from its operator’s published addresses, or pass its reverse DNS check, to get a saved copy |
unverifiable_crawlers |
snapshot |
With verification on, what crawlers with no published check get: snapshot or live |
flatten_shadow_roots |
true |
Write the content of open shadow roots (web components such as Lit or Stencil) into saved HTML, with slotted content in place |
flatten_frames |
true |
Write the body of same-origin iframes that loaded with status 200 into saved HTML, as a div marked data-rendercache-frame |
Admin endpoints
These live only on the admin listener (127.0.0.1:9090 by default), never on the public one. With a token set, send Authorization: Bearer <token> or sign in as rendercache with the token as password.
| Endpoint | What it does |
|---|---|
GET / |
The “What the bot sees” page: coverage, errors, receipts and the HTML comparison |
GET /healthz |
Process health |
GET /status |
Warming coverage, queue, cache counters and recent delivery receipts as JSON |
POST /purge?url=/path |
Queues a fresh render of one page and keeps the old copy until it succeeds. Always needs a token |
POST /diagnose |
Compares the raw origin HTML of {"url":"/path"} with the saved copy |
POST /reload |
Reads the config file again and applies bot patterns, bypass paths, ignored parameters, trusted proxies, tokens, the snapshot age and the verification settings; lists other changed settings as needing a restart |
POST /simulate |
Sends a local crawler-style request through the public handler and records a receipt marked simulated |
Response header
Every public response carries X-RenderCache:
| Value | Meaning |
|---|---|
HIT |
A fresh saved copy was served to a crawler |
STALE |
An older saved copy was served while a refresh runs in the background |
MISS |
A crawler asked for a page with no saved copy yet; the origin answered and a render was queued |
BYPASS |
Not eligible for a saved copy: a person, a request with cookies or credentials, an asset, a bypassed path, a non-GET request, or, with verify_crawlers on, a crawler claim whose address did not check out |