Skip to main content

Maintenance mode

Set MAINTENANCE_MODE=true and restart Hub. Hub pages plus /embed, /view, and /edit rewrite to /maintenance and return HTTP 503, with an optional Retry-After header. The address bar still shows the original path.

Share links (/share), Slack (/slack), and /api stay up. Use this for planned Hub downtime, not for a full API outage.

The page follows the visitor's light or dark system setting. It does not show the HTTP status. A construction icon sits above the heading, then the two paragraphs, then the quieter closing line.

Maintenance page: construction icon, We'll be right back, two short paragraphs, and a quieter thank-you lineMaintenance page: construction icon, We'll be right back, two short paragraphs, and a quieter thank-you line

Turn it on​

  1. Set MAINTENANCE_MODE=true in hub/.env or the process environment. Any other value, including false or empty, leaves the site up.
  2. (Optional) Set MAINTENANCE_RETRY_AFTER_SECONDS to a non-negative integer. Hub sends it as the Retry-After header. An invalid value is omitted.
  3. (Optional) Override the page copy. Empty values fall back to the defaults below.
  4. Restart the process. Local pnpm dev does not reload .env until you stop and start it again. pnpm run:standalone does not read hub/.env; export the variables in the shell or the container.
  5. Open a Hub route such as /forms and confirm 503 in the browser network panel. Do not use /share for this check.
  6. To restore service, remove MAINTENANCE_MODE or set it to anything other than true, then restart again.

Limitations​

These paths are excluded so the page can render, or so they stay available:

  • /maintenance — otherwise the rewrite would loop. It sets robots to noindex, nofollow.
  • /share and /slack — a published share link stays up.
  • /api — integrations keep calling Hub API routes unless the API process is down separately.
  • /_next/static, /_next/image, favicon.ico, and assets — CSS, scripts, and icons keep loading.
API callers still get 200

That is expected. A 503 for every API needs a separate policy (gateway, or your own route handling). It is not part of this switch.

Page copy​

MAINTENANCE_CARD_DESCRIPTION and MAINTENANCE_BODY are two paragraphs. MAINTENANCE_FOOTER is the quieter line under them. “Powered by Endatix” follows ENDATIX_SHOW_POWERED_BY.

One language per deployment. Hub does not read Accept-Language for this page. Set the six copy variables to the language you want everyone to see. Per-respondent language is respondent access denial, not maintenance mode.

MAINTENANCE_TITLE=Volveremos enseguida
MAINTENANCE_CARD_DESCRIPTION=Esta aplicación no está disponible temporalmente.
MAINTENANCE_BODY=Estamos realizando un mantenimiento programado. Vuelva a intentarlo pronto.
MAINTENANCE_FOOTER=Gracias por su paciencia.
MAINTENANCE_METADATA_TITLE=Mantenimiento programado
MAINTENANCE_METADATA_DESCRIPTION=La aplicación no está disponible temporalmente mientras realizamos el mantenimiento.

Quote the values if you export them in a shell. Spaces would otherwise split the assignment.

Set to true to enable the rewrite. Anything else means normal operation.

Non-negative integer, sent as Retry-After (seconds). Unset or invalid means no header.

MAINTENANCE_TITLEDefault We'll be right back

Main heading.

MAINTENANCE_CARD_DESCRIPTIONDefault This application is temporarily unavailable.

First paragraph under the heading.

MAINTENANCE_BODYDefault We're performing scheduled maintenance. Please check back soon. We apologize for the inconvenience.

Second paragraph.

MAINTENANCE_METADATA_TITLEDefault Scheduled maintenance

HTML title.

MAINTENANCE_METADATA_DESCRIPTIONDefault The application is temporarily unavailable while we perform maintenance.

Meta description.

Ignored. The page no longer shows a badge.

If it does not appear​

  • The value is not exactly true, or the process was not restarted after the .env change.
  • The URL is excluded. /share staying up is the matcher, not a failed deploy.
  • Styles or icons missing: /_next/static or favicon.ico is being rewritten. Those paths must stay excluded.

See also​