Configure the server
Settings are read in this order: command-line options → environment variables → JSON file → defaults. Use --config PATH or ARTIFACT_CONFIG to select a file. The local installer’s launcher selects its config file automatically.
Settings
| CLI option | Environment variable | JSON key | Default |
|---|---|---|---|
--allow-outside-requests | ALLOW_OUTSIDE_REQUESTS | allow_outside_requests | false locally; true in Docker |
--host | HOST | host | 127.0.0.1, or 0.0.0.0 when outside access is allowed |
--port | PORT | port | 3000 |
--public-url | PUBLIC_URL | public_url | http://localhost:PORT, or Railway’s HTTPS domain |
--data-dir | DATA_DIR | data_dir | ./data; installer uses its own data folder; Docker uses /data |
--username | ARTIFACT_USERNAME | username | Required; installer asks you to choose |
--password | ARTIFACT_PASSWORD | password | Required; at least 12 characters |
--api-token | ARTIFACT_API_TOKEN | api_token | Optional legacy token; at least 32 characters if set |
--max-artifact-bytes | MAX_ARTIFACT_BYTES | max_artifact_bytes | 268435456 (256 MiB) |
--max-asset-bytes | MAX_ASSET_BYTES | max_asset_bytes | 16777216 (16 MiB) |
--app-dir | APP_DIR | app_dir | Runtime folder; installer and Docker set this |
Boolean values are true or false. CLI options accept --port 3001 or --port=3001. Use config or environment variables for secrets; CLI arguments can appear in process listings.
A config file
{
"username": "admin",
"password": "REPLACE_WITH_A_UNIQUE_PASSWORD",
"allow_outside_requests": false,
"port": 3000,
"public_url": "http://localhost:3000",
"data_dir": "/home/you/.local/share/open-artifact/data",
"max_artifact_bytes": 268435456,
"max_asset_bytes": 16777216
}Replace the credentials and path, then restrict access to the file with chmod 600 config.json.
open-artifact --config config.json --check-config
open-artifact --config config.jsonUnknown fields, invalid values, and duplicate CLI options are rejected. The server does not watch the config file; restart after editing it.
Outside access
allow_outside_requests: false binds to loopback by default and rejects non-local peers, non-local Host headers, and forwarded requests. A non-loopback host or public public_url is rejected in this mode. This also helps prevent a web page from reaching your local server through DNS rebinding.
To accept outside traffic, set allow_outside_requests: true. host defaults to 0.0.0.0. Set public_url to your exact public origin, such as https://artifacts.example.com, and provide HTTPS through your hosting service or reverse proxy. The server itself speaks HTTP. Keep the owner password private. Public origins must use HTTPS.
Docker enables outside requests within the container by default. Your Docker port mapping still controls which host interfaces expose it. The quickstart maps to 127.0.0.1 so the server stays on your computer.
Storage and size limits
The data directory stores everything that belongs to your artifacts:
data/
catalog.sqlite
artifacts/
UUID/
artifact.sqlite
assets/ASSET_UUIDThe artifact database contains frontend source, editable components, compiled code, version history, saved state, and action records. Each artifact has a separate directory and database. Moving the data directory moves all of these together. Stop the service before copying it.
The artifact budget counts allocated SQLite pages and uploaded asset bytes, including all previous code versions. Rejected changes leave the last committed version and state intact. The asset limit checks decoded bytes before writing a file. Limits apply to each artifact independently.
SQLite journals and temporary compilation need extra disk space beyond these budgets. The catalog is shared server metadata and is not part of an artifact’s budget. There is no total-server quota: monitor available disk and keep backups. Use one process and one replica per data directory.
Artifact limits can be 1 MiB–1 TiB; asset limits can be 1 byte–256 MiB, and no greater than the artifact limit. Lowering a limit does not delete existing data; further writes must fit the new limit. Saved JSON state also has a 1 MB safety limit, and each artifact can have at most 128 assets.
Docker with a config file
Mount the file read-only and use an absolute data path inside the container:
docker run -d --name open-artifact \
-p 127.0.0.1:3000:3000 \
-v "$PWD/config.json:/app/config.json:ro" \
-v open-artifact-data:/data \
--restart unless-stopped \
dusanstanojeviccs/open-artifact:latest \
open-artifact --config /app/config.jsonThe container runs as UID 1000 after preparing the data volume. Give that user read access to the mounted config file. Docker’s built-in environment values for network access, storage, and runtime path override corresponding JSON values; use CLI flags to override them deliberately.
Connected AI clients
Browser authentication uses OAuth with PKCE. The server stores hashes of short-lived access tokens and rotating refresh tokens in its catalog. Authorization codes expire after five minutes and can be used once. Access tokens last one hour; an unused refresh token expires after 30 days. Disconnect clients from the library to revoke access immediately. Changing the admin credentials or public URL invalidates existing sessions and grants.