Environment Variables
Environment variables override the corresponding chatto.toml settings. Use the
names listed here; not every name follows the same section pattern. Check for
unknown or deprecated names with chatto config check --config chatto.toml.
See Check configuration.
Defaults below apply when a setting is omitted. chatto init also writes setup
choices: port 4000, URL http://localhost:4000, embedded NATS enabled with data
directory ./data, the asset worker enabled, SMTP port 587, and random secrets.
Set the same choices and provide secrets for an equivalent ENV-only deployment.
Commented values are examples; they do not override runtime defaults.
General
Section titled “General”CHATTO_LOG_LEVEL Log level. Values: debug, info, warn, error.
CHATTO_LOG_FORMAT Log output format. Values: auto, text, json, logfmt. auto uses text when Chatto is attached to a terminal and JSON otherwise. Use json for Loki/Grafana ingestion so each log line includes a structured level field.
Web Server
Section titled “Web Server”CHATTO_WEBSERVER_URL Public URL of the server, used for absolute links, public API asset URLs, and OAuth redirects. Set this to the external HTTPS origin when Chatto runs behind a reverse proxy; forwarded proxy headers are not trusted for public URL generation.
CHATTO_WEBSERVER_PORT Port to listen on. Required without built-in TLS. With TLS, an omitted port uses
443. chatto init writes 4000.
CHATTO_WEBSERVER_BIND_ADDRESS Address to listen on, without a port. Empty binds all interfaces. Set this to
127.0.0.1 to accept connections only from the same machine, for example through
a local reverse proxy. This also applies to the HTTP challenge and redirect
listener when built-in TLS is enabled.
CHATTO_WEBSERVER_COOKIE_SIGNING_SECRET 256-bit hex secret for signing browser-flow cookies and CSRF proofs. The opaque chatto_auth_* authentication cookies do not contain signed user data. Generate with openssl rand -hex 32.
CHATTO_WEBSERVER_COOKIE_ENCRYPTION_SECRET Optional hex secret for encrypting browser-flow cookies after signing. Must decode to 16, 24, or 32 bytes. Generate an AES-256 key with openssl rand -hex 32.
CHATTO_WEBSERVER_API_COMPRESSION Compress eligible ConnectRPC API responses with gzip. Disable this to reduce compressor memory and CPU at the cost of higher network usage. Chatto continues to accept compressed API requests.
CHATTO_WEBSERVER_API_COMPRESSION_MIN_BYTES Minimum uncompressed ConnectRPC response size, in bytes, eligible for gzip compression. Increase this threshold when small API responses do not save enough bandwidth to justify compressor memory and CPU.
CHATTO_WEBSERVER_WEBSOCKET_COMPRESSION Negotiate WebSocket compression. The realtime server compresses frames of at least 1 KiB with a Huffman-only encoder; smaller invalidation and heartbeat frames stay uncompressed and do not instantiate server-side compressor state.
CHATTO_WEBSERVER_REQUEST_LOGGING Log HTTP requests. Successful requests are debug-level and require CHATTO_LOG_LEVEL=debug; 4xx and 5xx responses remain visible at warning and error levels.
CHATTO_WEBSERVER_TRUSTED_PROXIES Comma-separated IP addresses or CIDR ranges for reverse proxies that Chatto may trust to supply X-Forwarded-For, X-Real-IP, and X-Forwarded-Host. The default is empty, so direct clients cannot spoof audit attribution or WebSocket same-origin checks with forwarded headers. Configure the narrow network used by your proxy—for example, 127.0.0.1 for a same-host proxy or the specific container-network CIDR—and make the proxy overwrite forwarded headers rather than preserving client-supplied values. This does not make forwarded protocol headers authoritative for public URL generation; continue setting webserver.url.
CHATTO_WEBSERVER_ALLOWED_ORIGINS Comma-separated exact additional HTTPS origins for reverse-proxy aliases. Each origin can use browser cookie authentication, publish a matching bundled frontend OAuth identity, and serve an origin-bound MCP resource. API responses to a request on that origin use it in absolute URLs, such as server images and webhook URLs. Do not include a path, query, or fragment. Do not configure HTTP and HTTPS origins that produce the same request host. Do not use *; it permits none of these behaviors.
Built-in automatic TLS via Let’s Encrypt. When enabled, Chatto handles certificate provisioning and renewal automatically.
CHATTO_WEBSERVER_TLS_ENABLED Enable automatic TLS via Let’s Encrypt. Requires ports 80 and 443 (or custom ports configured below).
CHATTO_WEBSERVER_TLS_DOMAIN Domain name for the TLS certificate. Required when TLS is enabled.
CHATTO_WEBSERVER_TLS_EMAIL Email address for Let’s Encrypt notifications. Required when TLS is enabled.
CHATTO_WEBSERVER_TLS_CACHE_DIR Directory to cache TLS certificates.
CHATTO_WEBSERVER_TLS_HTTP_PORT Port for the HTTP server (ACME challenges and HTTPS redirect). Use a higher port if running without elevated privileges.
Metrics
Section titled “Metrics”CHATTO_METRICS_ENABLED Expose a Prometheus-compatible per-process metrics endpoint on a separate internal HTTP listener.
CHATTO_METRICS_BIND_ADDRESS Address to bind the metrics listener. Keep this on localhost unless a trusted internal network or sidecar needs direct scrape access.
CHATTO_METRICS_PORT Port for the metrics listener.
CHATTO_METRICS_PATH HTTP path for Prometheus scrapes.
CHATTO_METRICS_PPROF Expose Go pprof debug endpoints on the metrics listener under /debug/pprof/. Keep the metrics listener private and enable this only while profiling.
Exporter
Section titled “Exporter”The exporter exposes deployment-wide Chatto metrics. Run it as chatto exporter against external NATS or an exposed embedded NATS TCP listener, or set exporter.enabled = true to embed it inside chatto run for single-process installs. Clustered deployments should enable the embedded exporter on at most one replica.
CHATTO_EXPORTER_ENABLED Start the deployment-wide Prometheus exporter inside chatto run.
CHATTO_EXPORTER_BIND_ADDRESS Address to bind the exporter listener. Keep this on localhost unless a trusted internal network or sidecar needs direct scrape access.
CHATTO_EXPORTER_PORT Port for the exporter listener.
CHATTO_EXPORTER_PATH HTTP path for Prometheus scrapes.
CHATTO_EXPORTER_S3_REFRESH_INTERVAL How often to refresh cached S3 bucket size metrics when S3 asset storage is configured.
CHATTO_EXPORTER_S3_TIMEOUT Timeout for one S3 bucket-size refresh.
Model Context Protocol
Section titled “Model Context Protocol”CHATTO_MCP_ENABLED Expose the experimental MCP routes on the public Chatto HTTP server. The endpoints use the webserver.url origin and each exact non-wildcard webserver.allowed_origins entry with the /mcp path.
Shields
Section titled “Shields”CHATTO_WEBSERVER_SHIELDS_ENABLED Expose public Shields.io-compatible badge endpoints for aggregate community counts. When enabled, /.well-known/chatto/shields/online.json and /.well-known/chatto/shields/registered.json return endpoint-badge JSON, while the matching .png URLs redirect to Shields.io-rendered badges. Leave disabled for private communities that should not publish size or activity counts.
Message Search
Section titled “Message Search”The consumer-facing feature and bundled provider have separate switches. This lets you expose Search through Chatto while running a compatible provider separately, or embed the bundled Bleve provider in chatto run for a single-process deployment.
See Enabling Search for a complete setup guide, analyzer names, storage guidance, and troubleshooting.
CHATTO_SEARCH_ENABLED Enable consumer-facing message queries. Compatible clients discover the Search protocol independently and use the Search status RPC to distinguish disabled, indexing, ready, degraded, and unavailable states.
CHATTO_SEARCH_PROVIDER_ENABLED Start the bundled Bleve provider inside chatto run. This does not by itself expose the consumer-facing Search feature.
CHATTO_SEARCH_PROVIDER_DIRECTORY Directory for the bundled provider’s disposable local index. Protect this directory like message data: it contains plaintext-derived search content, is not included in Chatto backups, and can be rebuilt from retained EVT history. Do not set it to the embedded NATS data directory or one of its parent directories.
CHATTO_SEARCH_PROVIDER_LANGUAGES Comma-separated Bleve analyzer codes to use when indexing messages and analyzing queries. Supported values are ar, cjk, ckb, da, de, en, es, fa, fi, fr, hi, hr, hu, it, nl, no, pl, pt, ro, ru, sv, and tr. Changing the set automatically rebuilds a recognized Chatto index on restart. See index recovery if startup reports an error. Use none for language-neutral literal and typo-tolerant matching only; the TOML equivalent is languages = [].
Diagnostics
Section titled “Diagnostics”CHATTO_DIAGNOSTICS_STARTUP_CPU_PROFILE Write a Go CPU profile covering process startup through core boot to this path. Useful for local projection replay benchmarking; disabled when empty.
Operator API
Section titled “Operator API”CHATTO_OPERATOR_API_ENABLED Enable the local root-equivalent Operator API Unix socket for chatto operator ... commands. The public web listener never serves this API.
CHATTO_OPERATOR_API_SOCKET_PATH Unix socket path for local operator commands. The socket mode is fixed at 0600; Docker users should normally run chatto operator ... inside the running container with docker exec.
CHATTO_CORE_SKIP_SETUP_WIZARD Disable the first-run web setup wizard. Use this for installations where you create accounts through the local operator API. The flag does not change or reset durable initialization state. Use the same value on all replicas. Existing servers skip the wizard automatically.
CHATTO_CORE_EVT_READ_CACHE_IDLE_TTL Keep an EVT record in each server process’s timeline read cache for this duration after its last access. A shorter duration reduces idle memory use and can cause more NATS reads. A longer duration can make repeated timeline reads faster and use more memory. Supports values such as 15m and 1h.
CHATTO_CORE_EVT_READ_CACHE_MAX_BYTES Set the approximate maximum size of each server process’s timeline read cache. Chatto evicts the least-recently-used EVT records when the cache exceeds this limit. Supports values such as 128MiB and 1GiB. Set this value to -1 to disable the byte limit. The idle timeout remains active. Chatto logs both effective cache settings at info level during startup. Set CHATTO_LOG_LEVEL=debug to also log cache hit and miss summaries, read durations, LRU eviction counts, expiry counts, and cache clears.
CHATTO_CORE_PROJECTION_SNAPSHOTS Persist encrypted projection snapshots and replay only the later EVT delta for eligible projections at startup. Chatto treats EVT as authoritative and automatically replays it when a snapshot is missing, incompatible, corrupt, expired, or unavailable. User profile state is eligible, but password verifiers, external identities, and OAuth consent remain outside snapshots and cold-replay from focused event subjects. One elected replica attempts publication after boot and every 23–24 hours.
CHATTO_CORE_PROJECTION_SNAPSHOT_RETENTION Retain projection snapshot generations for this duration. NATS applies the duration as the dedicated Object Store TTL. Chatto uses it as the cutoff for optional S3 expiry. Supports values such as 7d, 1w, and 168h.
CHATTO_CORE_PROJECTION_SNAPSHOT_S3_CLEANUP Delete marked S3 projection snapshot generations older than core.projection_snapshot_retention. Disable this when the bucket has an external lifecycle policy for internal/projection-snapshots/. When enabled, S3 credentials need permission to list that prefix, inspect object metadata, and delete matching objects. Chatto validates the exact internal generation path, content type, and object-purpose marker before deletion; asset paths are never eligible.
CHATTO_CORE_SECRET_KEY 256-bit hex secret for HMAC-derived bearer-token, cookie-session, OAuth-code, account-flow, and invitation-code verifiers. Generate with openssl rand -hex 32. Keep this stable across restores if you want sessions, pending credentials, and existing invitation codes to remain valid. Changing it invalidates distributed codes without deleting their durable invitation records; authorised administrators can copy newly derived codes. It also makes projection snapshots unreadable, which Chatto safely rebuilds from EVT.
Assets
Section titled “Assets”CHATTO_CORE_ASSETS_SIGNING_SECRET 256-bit hex secret for signing asset URLs. Generate with openssl rand -hex 32.
CHATTO_CORE_ASSETS_MAX_UPLOAD_SIZE Maximum upload size for all files, including images, GIFs, and videos (e.g., 25MB, 25 MiB). Video upload enablement does not change this limit.
CHATTO_CORE_ASSETS_STORAGE_BACKEND Storage backend for persisted assets. Values: nats, s3.
S3 Storage
Section titled “S3 Storage”Only used when storage_backend is set to s3. See the S3 Storage guide for setup instructions.
CHATTO_CORE_ASSETS_S3_ENDPOINT S3 endpoint URL (e.g., s3.amazonaws.com for AWS, or a custom endpoint for S3-compatible services).
CHATTO_CORE_ASSETS_S3_BUCKET S3 bucket name. Created automatically on startup if it doesn’t exist.
CHATTO_CORE_ASSETS_S3_PATH_PREFIX Optional object key prefix for all S3 assets. Leave empty to store objects at the bucket root.
CHATTO_CORE_ASSETS_S3_REGION AWS region. Optional for non-AWS S3-compatible services.
CHATTO_CORE_ASSETS_S3_ACCESS_KEY_ID S3 access key ID.
CHATTO_CORE_ASSETS_S3_SECRET_ACCESS_KEY S3 secret access key.
CHATTO_CORE_ASSETS_S3_USE_SSL Use HTTPS for S3 connections.
CHATTO_CORE_ASSETS_S3_PATH_STYLE Override S3 URL addressing. By default, Chatto uses virtual-hosted addressing for AWS S3 endpoints and path-style addressing for custom S3-compatible endpoints.
Image Cache
Section titled “Image Cache”Chatto always caches resized images and Neighborhood images for seven days.
Remove the obsolete [core.assets.cache] section and the
CHATTO_CORE_ASSETS_CACHE_ENABLED and CHATTO_CORE_ASSETS_CACHE_TTL
environment variables from your configuration. These settings no longer have an effect.
CHATTO_NATS_REPLICAS Number of replicas for JetStream streams, KV buckets, and object stores. Must be an odd number (1, 3, or 5) for quorum. Set to 3 or 5 when running a NATS cluster for fault tolerance.
Embedded Server
Section titled “Embedded Server”CHATTO_NATS_EMBEDDED_ENABLED Enable the embedded NATS server. chatto init writes true. Set to false when connecting to an external NATS server.
CHATTO_NATS_EMBEDDED_PORT Embedded NATS server port. Leave unset or set to 0 for in-process only mode. Set to 4222 or another port to expose a TCP listener for NATS CLI/admin commands.
CHATTO_NATS_EMBEDDED_BIND_ADDRESS Embedded NATS server bind address.
CHATTO_NATS_EMBEDDED_HTTP_PORT NATS monitoring/stats HTTP port. Set to 0 to disable. Useful for debugging with the NATS dashboard.
CHATTO_NATS_EMBEDDED_DATA_DIR JetStream data directory for the embedded server. Set an explicit persistent
directory. chatto init writes ./data.
CHATTO_NATS_EMBEDDED_SYNC_INTERVAL Set how often embedded JetStream syncs file data to disk. Use a duration such as 30s, or use always to sync every write before NATS acknowledges it. Set this to always when you use a single NATS server and data durability is more important than maximum write throughput. If you omit this setting, Chatto keeps the NATS default.
CHATTO_NATS_EMBEDDED_AUTH_TOKEN Auth token for the embedded NATS server. When the embedded TCP port is enabled, Chatto derives matching nats.client defaults for CLI/admin commands unless you override them explicitly.
Client
Section titled “Client”CHATTO_NATS_CLIENT_URL NATS server URL to connect to when using external NATS or an exposed embedded TCP listener. Supports comma-separated URLs for cluster failover (e.g., nats://n1:4222,nats://n2:4222).
CHATTO_NATS_CLIENT_AUTH_METHOD NATS authentication method for external NATS or an exposed embedded TCP listener. Values: none, token, userpass, credentials, nkey.
CHATTO_NATS_CLIENT_TOKEN NATS auth token (when using token auth method). When explicitly set alongside embedded NATS, it must match CHATTO_NATS_EMBEDDED_AUTH_TOKEN.
CHATTO_NATS_CLIENT_USERNAME NATS username (when using userpass auth method).
CHATTO_NATS_CLIENT_PASSWORD NATS password (when using userpass auth method).
CHATTO_NATS_CLIENT_CREDENTIALS_FILE Path to .creds file (when using credentials auth method).
CHATTO_NATS_CLIENT_NKEY_SEED NKey seed (when using nkey auth method).
CHATTO_NATS_CLIENT_CA_CERT PEM-encoded CA certificate for verifying the NATS server’s TLS certificate. When set, the NATS client connection uses TLS.
Authentication
Section titled “Authentication”CHATTO_AUTH_DIRECT_REGISTRATION Enable direct (email/password) registration. When false, the registration page is hidden and the registration API returns 403. Existing users can still sign in through enabled password login or configured SSO providers.
CHATTO_AUTH_DIRECT_LOGIN Enable direct sign-in with a username or email address and password. When false, the password login form and recovery link are hidden. Password sign-in, user password changes, and password recovery are disabled on the server. Account settings shows disabled password controls with an SSO notice. Sensitive account actions require fresh SSO authentication instead of local password proof. Existing sessions, stored passwords, registration, and operator recovery are unaffected.
CHATTO_AUTH_TOKEN_TTL Renewal window for active human sessions and initial lifetime of each same-origin cookie credential. Active bearer sessions advance this window during background refresh. In the final quarter, the bundled browser automatically renews the same cookie handle through a dedicated route. Ordinary validation does not write the session. An inactive session expires after one complete window. Supports durations like 90d or 2160h.
CHATTO_AUTH_ACCESS_TOKEN_TTL Fixed lifetime of each human bearer access token. Validation does not renew it; compatible clients rotate the paired refresh credential before expiry. Supports durations like 15m, 30m, or 1h.
CHATTO_AUTH_LOOPBACK_CLIENT_ENABLED Let the Chatto web client sign in to this server when the client runs on a local address of the member’s device, for example a development server on localhost. The client uses the built-in chatto://loopback identity. Its sessions end at most 24 hours after sign-in and do not renew. When you set this to false, existing sessions of this client also stop working. Upgrade every serving replica before you enable this setting, and use the same value on every replica. Sign-ins made while replicas use different values can end, and members must then sign in again. See Clients From Other Origins.
CHATTO_AUTH_EMAIL_OTP_THROTTLING_ENABLED Enable throttling for registration and email-verification code delivery and wrong-code attempts. Set to false to disable these throttles while keeping OTP TTL enforcement.
CHATTO_AUTH_EMAIL_OTP_TTL How long registration and email-verification codes remain valid. Supports durations like 15m, 30m, or 1h.
CHATTO_AUTH_EMAIL_OTP_MAX_DELIVERED_CODES Maximum successfully delivered registration or email-verification codes allowed for the same email challenge before fresh code requests are throttled.
CHATTO_AUTH_EMAIL_OTP_MAX_WRONG_ATTEMPTS Maximum wrong-code submissions allowed for the same email challenge before the challenge is exhausted until its TTL expires.
External Login Providers
Section titled “External Login Providers”External login providers are configured as repeated [[auth.providers]] tables in chatto.toml.
Supported provider types are oidc, github, gitlab, google, and discord.
CHATTO_AUTH_PROVIDERS_<index>_<field> Counted environment-variable equivalent of repeated [[auth.providers]] tables. Indexes start at 0 and must not have gaps. Supported fields are ID, TYPE, LABEL, CLIENT_ID, CLIENT_SECRET, TOKEN_ENDPOINT_AUTH_METHOD, ISSUER_URL, SCOPES, REQUEST_EMAIL, AUTO_PROVISION, ALLOWED_GROUPS, GROUPS_CLAIM, and GROUP_ROLES. GROUP_ROLES takes space-separated group:role pairs, the same as the TOML value. SCOPES and ALLOWED_GROUPS take comma-separated lists. An empty ALLOWED_GROUPS value is an error. Use chatto.toml for group names that contain commas. CLIENT_SECRET is optional only for public OIDC clients; OAuth provider types still require it.
For compatibility with older single-provider OIDC deployments, Chatto also accepts CHATTO_AUTH_OIDC_ENABLED, CHATTO_AUTH_OIDC_ISSUER_URL, CHATTO_AUTH_OIDC_CLIENT_ID, CHATTO_AUTH_OIDC_CLIENT_SECRET, and optional CHATTO_AUTH_OIDC_LABEL. These create one oidc provider with id = "oidc". Do not combine them with counted CHATTO_AUTH_PROVIDERS_<index>_* variables.
[[auth.providers]]id = "chatto-hub"type = "oidc"label = "Chatto Hub"issuer_url = "https://hub.chatto.dev"client_id = "..."client_secret = "..."auto_provision = falseProvider IDs are used in login URLs and external identity links, so do not change them after users link accounts through that provider.
request_email defaults to false, so Chatto does not request provider email scopes unless you opt in. Set request_email = true when you want provider-verified email claims. OIDC providers can run with only openid profile; Chatto links and signs in accounts by issuer and subject even when no email claim is returned.
CHATTO_AUTH_PROVIDERS_0_TOKEN_ENDPOINT_AUTH_METHOD sets the OIDC-only
token_endpoint_auth_method option: client_secret_basic, client_secret_post,
or none. Basic and POST require a secret; none forbids one. Omit the option
to use public-client authentication without a secret, or discovery-selected
Basic/POST with a secret. See token authentication configuration.
For a CIMD-capable OIDC provider, set CHATTO_AUTH_PROVIDERS_<index>_CLIENT_ID to {webserver.url}/oauth/client-metadata.json and omit CHATTO_AUTH_PROVIDERS_<index>_CLIENT_SECRET. Chatto then publishes the public client metadata at that URL. See the External Login Providers guide for an example.
To allow only the members of some groups of an OIDC provider, set allowed_groups. To give roles to group members, set group_roles. See Map groups to roles. See Restrict who can sign in.
Set auto_provision = true only for providers whose users should be allowed to create accounts. Unlinked identities from providers without auto-provisioning can still be linked by existing signed-in users from account settings.
Provider account settings also support counted environment variables:
| TOML option | Environment suffix after CHATTO_AUTH_PROVIDERS_0_ | Default |
|---|---|---|
manage_usernames | MANAGE_USERNAMES | false |
update_usernames | UPDATE_USERNAMES | false; requires manage_usernames |
username_claim | USERNAME_CLAIM | preferred_username; OIDC only |
allow_unlinking | ALLOW_UNLINKING | true |
See managed usernames and account links for collision handling, existing accounts, and operator controls.
See External Login Providers for callback URLs, provider-specific examples, and discovery behavior.
Transactional Email
Section titled “Transactional Email”SMTP is the default transactional email transport. Set email.transport = "jmap" when your provider exposes JMAP submission and you want Chatto to authenticate with a bearer token instead.
CHATTO_EMAIL_TRANSPORT Transactional email transport. Supported values are smtp and jmap.
CHATTO_EMAIL_JMAP_SESSION_URL HTTPS JMAP session resource URL. Required when email.transport is jmap.
CHATTO_EMAIL_JMAP_ACCESS_TOKEN Bearer access token for the JMAP account. Required when email.transport is jmap.
CHATTO_EMAIL_JMAP_FROM From address for outgoing email. It must match a sending identity in the JMAP account. Required when email.transport is jmap.
CHATTO_EMAIL_JMAP_ACCOUNT_ID Optional JMAP account ID. By default, Chatto uses the session’s primary submission account.
CHATTO_EMAIL_JMAP_IDENTITY_ID Optional JMAP identity ID. By default, Chatto uses the identity matching email.jmap.from.
CHATTO_EMAIL_JMAP_DRAFT_MAILBOX_ID Optional JMAP Drafts mailbox ID. By default, Chatto uses the mailbox with the drafts role.
CHATTO_SMTP_ENABLED Enable SMTP email sending.
CHATTO_SMTP_HOST SMTP server hostname.
CHATTO_SMTP_PORT SMTP port. Common values: 587 for STARTTLS, or 465 for implicit TLS/SMTPS.
CHATTO_SMTP_TLS SMTP TLS policy. Use mandatory to require STARTTLS on port 587, or implicit for SMTPS on port 465. When this value is omitted or left as mandatory, Chatto automatically uses implicit TLS for port 465. Use opportunistic only when the SMTP server cannot support mandatory STARTTLS and plaintext fallback is explicitly acceptable. Chatto logs a warning at startup when this value is opportunistic.
CHATTO_SMTP_TLS_SERVER_NAME SMTP TLS server name for certificate verification and SNI. Use when smtp.host is an IP address or internal alias but the certificate is issued for a DNS name.
CHATTO_SMTP_TLS_SKIP_VERIFY Disable SMTP TLS certificate verification. Insecure; use only for trusted internal SMTP servers with self-signed or mismatched certificates. Chatto logs a warning at startup when this value is true.
CHATTO_SMTP_USERNAME SMTP username.
CHATTO_SMTP_PASSWORD SMTP password.
CHATTO_SMTP_FROM From address for outgoing emails.
Push Notifications
Section titled “Push Notifications”CHATTO_PUSH_ENABLED Enable Web Push notifications.
CHATTO_PUSH_VAPID_PUBLIC_KEY VAPID public key for Web Push. Generate with npx web-push generate-vapid-keys.
CHATTO_PUSH_VAPID_PRIVATE_KEY VAPID private key for Web Push.
CHATTO_PUSH_VAPID_SUBJECT VAPID subject identifier. Use an operator email address, optionally prefixed with mailto:, or an https: contact URL.
Asset Processing
Section titled “Asset Processing”CHATTO_ASSET_PROCESSING_ENABLED Start the built-in durable asset-processing worker inside chatto run. chatto init writes this as true for a self-contained default installation. The explicit chatto asset-processing command runs regardless of this setting.
CHATTO_ASSET_PROCESSING_FFMPEG_PATH Path to the ffmpeg binary. If not set, Chatto looks for ffmpeg in PATH.
CHATTO_ASSET_PROCESSING_FFPROBE_PATH Path to the ffprobe binary. If not set, Chatto looks for ffprobe in PATH.
CHATTO_ASSET_PROCESSING_MAX_CONCURRENT_JOBS Maximum number of jobs to process concurrently in each worker process. Higher values use more CPU and memory.
CHATTO_ASSET_PROCESSING_TEMP_DIR Directory for temporary files during transcoding. Defaults to the system temp directory.
Video Processing
Section titled “Video Processing”CHATTO_VIDEO_ENABLED Allow video uploads and enqueue their derivative processing. At least one embedded or standalone asset-processing worker must have ffmpeg and ffprobe available.
CHATTO_VIDEO_MAX_UPLOAD_SIZE Deprecated. Set CHATTO_CORE_ASSETS_MAX_UPLOAD_SIZE to the desired limit for all files, then remove this setting. While this setting is present, the larger of it and the general limit applies to all files, even when video uploads are disabled. An absent general limit uses its 25 MB default. The old implicit 100 MB video default no longer applies.
LiveKit (Voice & Video Calls)
Section titled “LiveKit (Voice & Video Calls)”CHATTO_LIVEKIT_ENABLED Enable LiveKit voice and video call support. Requires a running LiveKit server.
CHATTO_LIVEKIT_URL LiveKit server WebSocket URL. Use ws:// for development, wss:// for production.
CHATTO_LIVEKIT_API_KEY LiveKit API key for authentication.
CHATTO_LIVEKIT_API_SECRET LiveKit API secret for signing JWT tokens. Keep this confidential.
CHATTO_LIVEKIT_SERVER_ID Unique identifier for this Chatto server, prefixed to deterministic LiveKit room names. This value must match across replicas of one Chatto server, and should differ only across different Chatto servers sharing the same LiveKit cluster. When empty, room names use the unprefixed format. The old CHATTO_LIVEKIT_INSTANCE_ID / livekit.instance_id name is still accepted as a deprecated alias.
CHATTO_LIVEKIT_INSTANCE_ID Deprecated alias for CHATTO_LIVEKIT_SERVER_ID / livekit.server_id. Prefer the server ID name in new deployments.
CHATTO_LIVEKIT_WEBHOOK_API_KEY API key that LiveKit uses to sign webhook requests. When multiple Chatto servers share a LiveKit cluster, the webhook signing key may differ from the per-server API key. Falls back to CHATTO_LIVEKIT_API_KEY when not set.
CHATTO_LIVEKIT_WEBHOOK_API_SECRET API secret for validating webhook signatures. Falls back to CHATTO_LIVEKIT_API_SECRET when not set.
Owners
Section titled “Owners”CHATTO_OWNERS_EMAILS Comma-separated list of email addresses that confer server-owner status. A user with any verified email matching the list gets full server access (including /admin routes). Only verified email addresses are matched.
Limits
Section titled “Limits”Server-wide resource limits. Use -1 for unlimited (the default), 0 to disable creation entirely, or any positive integer to cap.
CHATTO_LIMITS_MAX_USERS Maximum number of verified accounts on this server. An account counts once it has at least one verified sign-in factor: a verified email or a linked SSO identity. Enforced when accounts are created and when the first verified factor is added. Note that the check is non-atomic, so a burst at the boundary can briefly overshoot by one or two.
Outbound bot webhooks
Section titled “Outbound bot webhooks”[core.bot_webhooks]max_attempts = 5retry_delay = "30s"expiry = "24h"| Environment variable | TOML key | Default | Meaning |
|---|---|---|---|
CHATTO_CORE_BOT_WEBHOOKS_MAX_ATTEMPTS | core.bot_webhooks.max_attempts | 5 | Maximum delivery attempts, including the first attempt. Range: 1–100. |
CHATTO_CORE_BOT_WEBHOOKS_RETRY_DELAY | core.bot_webhooks.retry_delay | 30s | Initial delay. Range: 1 second–30 minutes. Doubles after each failed attempt, up to 30 minutes. |
CHATTO_CORE_BOT_WEBHOOKS_EXPIRY | core.bot_webhooks.expiry | 24h | Lifetime from the source message time. Range: 1 second–30 days. |
Restart the server after a change. Delivery and retries are best effort.
Restart discards pending work and retry timers. A source event accepted after
restart uses the new attempt limit and retry delay; expiry is still measured
from the original message time. Attempts include failures before HTTP starts.
The network policy is checked on each attempt. Destinations require public
HTTPS, except localhost and *.localhost, which permit HTTP and HTTPS only
when every resolved address is loopback. IP literals do not receive this
exception. Redirects are not followed.
See outbound bot webhooks for the request body, signature scheme, and receiver requirements.
Operational log
Section titled “Operational log”[core.log]retention = "7d"| Environment variable | TOML key | Default | Description |
|---|---|---|---|
CHATTO_CORE_LOG_RETENTION | core.log.retention | 7d | Retention of operational diagnostics. Minimum: 1 second. Zero selects the default. |
LOG retains terminal outbound webhook failures across server replicas. Expired records are removed and cannot be recovered. LOG is excluded from backups. Retention limits record age; it does not impose a fixed byte limit. Use the same configuration on all replicas.
Development bot bootstrap
Section titled “Development bot bootstrap”Builds with the bootstrap tag can create bots on an empty server. Release
builds ignore bootstrap settings. Later starts do not change existing data.
| Environment variable | TOML key within [[bootstrap.bots]] | Description |
|---|---|---|
CHATTO_BOOTSTRAP_BOTS_0_BIO | bio | Optional public Markdown bio, set only when the bot is first created. |
CHATTO_BOOTSTRAP_BOTS_0_CREDENTIAL_FILE | credential_file | File for the initial API key, written with owner-only permissions. |
CHATTO_BOOTSTRAP_BOTS_0_OUTBOUND_WEBHOOK_URL | outbound_webhook_url | Optional destination for an enabled outbound webhook named Local development. The signing secret is not exported. |
Use consecutive indices from zero for additional bots. The development stack sets these values for TestBot and points its webhook at the local Runling port.