Environment variables
Every setting is an environment variable and, except CONFIG_FILE, also a key in the
YAML file (the lower-case name, for example show_details). Environment variables
win over the file. See Configuration for
examples.
Boolean values accept true, false, 1, 0, yes and no.
| Variable | Default | Meaning |
|---|---|---|
THEME | glass | glass, terminal, classic, status or clean; a comma-separated list of them, or random for all five, to pick one at random on every page load. Repeated names count once. random cannot be combined with names. See Themes. |
DEFAULT_PAGE | 404 | Page for requests that name no error code. Any code or page name from Status codes. |
LANGUAGES | de,en,pl,fr | Comma-separated languages on offer, in the order of the language switch. Allowed: de, en, pl, fr. At least one; no duplicates. |
DEFAULT_LANGUAGE | en | Used when no language is detected. Must be one of LANGUAGES. |
SEND_SAME_HTTP_CODE | true | Answer with the page’s real status code instead of 200. |
SHOW_DETAILS | true | Show time, host and request ID (status theme only). |
SHOW_FOOTER | true | Show the footer. |
SHOW_VERSION | true | Show the version in the footer. |
COPYRIGHT_NAME | empty | Name after the © sign in the footer. |
COPYRIGHT_URL | empty | Optional link for the name. http(s) address or a path starting with /. |
LINKS | empty | Footer links as a JSON array. See Footer links. |
MAINTENANCE | false | Start in maintenance mode. |
MAINTENANCE_FILE | /data/maintenance | Flag file that switches maintenance mode on while it exists. |
MAINTENANCE_UNTIL | empty | Expected end of maintenance, RFC 3339 (2026-12-01T18:00:00Z). |
TEXTS_DIR | empty | Directory with text override files. See Custom texts. |
LISTEN | :8080 | Address the server listens on. |
CONFIG_FILE | empty | Path to a YAML configuration file. |
Commands
Section titled “Commands”The image’s entrypoint is /error-pages. Without arguments it runs serve.
| Command | What it does |
|---|---|
serve | Run the HTTP server (the default). |
healthcheck | Probe /healthz on the local listener; exit code 0 if healthy. |
maintenance on [--until RFC3339] | Switch maintenance mode on, optionally with an end time. |
maintenance off | Switch it off (removes the flag file). |
maintenance status | Print off, on or on until <time>. |
version | Print the version. |
Endpoints
Section titled “Endpoints”| Request | Response |
|---|---|
GET /{code} or /{code}.html | The page for that code. |
GET /internal, /internal.html | The internal-only page. |
GET /maintenance, /maintenance.html | The maintenance page. |
| any other path | The default page (DEFAULT_PAGE). |
GET /healthz | 200 ok, plain text. |
Every page is self-contained: its styles, fonts and scripts are part of the page, so a browser needs exactly one request and nothing else is served.
Response headers
Section titled “Response headers”Pages are sent with Cache-Control: no-store and these security headers:
Content-Security-Policy, X-Content-Type-Options: nosniff,
Referrer-Policy: no-referrer and X-Frame-Options: DENY. Content-Language names
the language of the page, and the maintenance page carries Retry-After when an end
time is known. No Server header is sent.
The Content Security Policy allows nothing but the page’s own inline style and script,
named by their SHA-256 hashes, and embedded data: fonts and images:
default-src 'none'; img-src data:; font-src data:; style-src 'sha256-…'; script-src 'sha256-…'; base-uri 'none'; form-action 'none'; frame-ancestors 'none'The hashes depend on the theme and the version and stay the same for every page the running container serves in that theme. With several themes (see Random theme) each response carries the hashes of the theme it was rendered with. JSON and plain-text responses always carry those of the first theme in the list.