Getting started

Configuration

Every environment variable Papyra reads, what it is for, and when you actually need it. Most people need none of them.

Papyra is configured by environment variables. Every one is optional. The defaults are what most installations want.

The full list

VariableDefaultWhat it does
PAPYRA_DATA_DIR/dataWhere notes, cache and keys live.
PAPYRA_ALLOW_INSECURE_COOKIESfalseAllow the session cookie over plain HTTP.
PAPYRA_ALLOWED_ORIGINS—Extra CORS origins, comma-separated.
PAPYRA_TRUSTED_PROXIES—Proxy IPs whose forwarded headers to believe.
PAPYRA_WEBAUTHN_DOMAINlocalhostBare hostname passkeys are bound to.
PAPYRA_WEBAUTHN_ORIGINS—Full origins passkeys may be used from.
PAPYRA_WHISPER_MODEL_PATH—Enables audio transcription.
PAPYRA_OCR_TESSDATA_PATH—Enables OCR of images.
PAPYRA_UPDATE_CHECK_ENABLEDtrueThe daily check for a newer version. Set false to turn it off.
PAPYRA_NTFY_URL, PAPYRA_NTFY_TOKEN—Set ntfy up on first start instead of in Settings. Read once. Details.
PAPYRA_TELEGRAM_BOT_TOKEN—Set the Telegram bot up on first start. Read once. Details.
PAPYRA_COLLAB_ENABLEDtrueLive editing of shared notes, run by an engine the server starts inside the same container. Set false and it never starts; /health reports whether it is running.
PAPYRA_SQLITE_WALtrueRun the database in WAL mode, which is faster under load. Set false if /data is on a network share (NFS, SMB), where WAL is unsafe.
PAPYRA_ERROR_DETAILStrueShow a short stack trace on the error page. Set false to show only the reference.
PUID / PGID1000Who owns the files on disk.
TZUTCDefault time zone, as an IANA name (Europe/London, Asia/Kolkata). Each person can pick their own under Settings → Profile.

Lists are comma-separated, as in every other container image.

Papyra also accepts .NET’s own spelling (Papyra__AllowInsecureCookies, Cors__AllowedOrigins__0), and anything set that way wins. The plain-English names exist because the .NET convention fails silently: get the casing or the doubled underscore subtly wrong and the setting is ignored with no error at all, which is the worst possible failure for something you touch once.

The ones you are most likely to need

PAPYRA_ALLOW_INSECURE_COOKIES

Set true only when Papyra is reached over plain HTTP on a network that is already private. It makes the session cookie non-Secure, which is exactly the thing HTTPS is protecting. See HTTPS and reverse proxies.

PAPYRA_UPDATE_CHECK_ENABLED

Once a day Papyra looks at GitHub to see whether a newer version is out, so admins can be told. It sends nothing about your server. It is optional. Set false and the server never makes that request, and admins simply aren’t told about new versions:

PAPYRA_UPDATE_CHECK_ENABLED: "false"

See The update check for exactly what it asks.

PAPYRA_TRUSTED_PROXIES

Behind a reverse proxy, every request arrives from the proxy’s address. Without this, your rate limits and logs see one client (the proxy), and a single visitor can exhaust everybody’s budget.

List the proxy’s IP and Papyra will believe its forwarded headers:

PAPYRA_TRUSTED_PROXIES: "172.18.0.1"

Only list proxies you control. An unlisted proxy cannot spoof a client address past the rate limiter, which is the point.

PAPYRA_ALLOWED_ORIGINS

Only needed if you serve the web app from a different address than the API. The standard deployment serves both from one process at one origin, so normally you leave this out entirely.

PAPYRA_WEBAUTHN_DOMAIN and PAPYRA_WEBAUTHN_ORIGINS

Passkeys are bound to a domain by the browser, and it must be the bare hostname, with no scheme, port or path:

PAPYRA_WEBAUTHN_DOMAIN: "notes.example.com"
PAPYRA_WEBAUTHN_ORIGINS: "https://notes.example.com"

Passkeys require real HTTPS. They will not work over plain HTTP outside localhost, and no configuration flag changes that. It is the browser’s rule.

Configured in the app, not the environment

Deliberately not environment variables, because changing them should not mean editing a compose file and restarting a container:

  • SSO / OIDC: Administration → Single sign-on, applied without a restart
  • SMTP: Administration → Email
  • Notification services (ntfy, Discord, Telegram): Administration → Notifications. See Notifications
  • Trash retention: Settings → Your data
  • Git backup: Settings → Git backup, per account

Optional extras, off unless configured

PAPYRA_WHISPER_MODEL_PATH enables local audio transcription, and PAPYRA_OCR_TESSDATA_PATH enables OCR of images into searchable text. Both are no-ops until you point them at model data, and neither sends anything anywhere.

Something wrong or missing? Improve this page on GitHub.