Skip to main content
This is the exhaustive lookup — every variable Activepieces reads, grouped by concern, with its default. For how to apply them to a production deployment, see Configure & Operate.
When you run tools/deploy.sh from the Docker installation tutorial, it generates a root .env file pre-filled with these values.
Variables marked ❗ are required for a self-hosted production deployment.

Core

URLs, encryption keys, telemetry.

Database

Postgres / PGLite connection and pooling.

Redis & queue

Standalone, Sentinel, and the queue UI.

Execution & sandboxing

Run mode, memory, concurrency, network egress.

Limits & retention

File, log, webhook, and table limits.

File storage (S3)

Object storage for files and logs.

Email (SMTP)

Outbound mail configuration.

Authentication & SSO

Google sign-in, SCIM, cloud OAuth.

Pieces & flows

Piece syncing, polling, publish behavior.

Core

Identity and connectivity for the platform: the public URL, the keys that protect connections and tokens, and telemetry.
VariableDescriptionDefault
AP_FRONTEND_URLThe public URL used to build redirect URLs and webhook URLs. It must be reachable by third parties for webhooks and app triggers to work.None
AP_ENCRYPTION_KEY32-character (16-byte) hexadecimal key used to encrypt connections. Generate one with openssl rand -hex 16.None
AP_JWT_SECRET32-character hexadecimal key used to sign JWT tokens. Generate one with openssl rand -hex 32.None
AP_CONFIG_PATHPath where the PGLite database and local settings are stored.~/.activepieces
AP_INTERNAL_URL(Beta) Internal URL used for SSO authentication, e.g. https://demo.activepieces.com/api.None
AP_TELEMETRY_ENABLEDCollect anonymous telemetry.true
AP_FRONTEND_URL is essential for webhooks and app triggers. It must be accessible to third parties so they can send data.
The default URL is the machine’s IP address. If that address isn’t reachable from the internet, set AP_FRONTEND_URL explicitly. For local development you can expose the frontend port (4200) with a tunneling service such as ngrok.

Database

Activepieces stores its data in PostgreSQL (recommended for production) or an embedded PGLite database. Set the connection with discrete fields or a single AP_POSTGRES_URL.
VariableDescriptionDefault
AP_DB_TYPEPOSTGRES for external PostgreSQL, PGLITE for the embedded database. SQLITE3 is deprecated and auto-migrated to PGLITE.POSTGRES
AP_POSTGRES_URLFull connection string (e.g. postgres://user:password@host:5432/database). When set, the discrete fields below are ignored.None
AP_POSTGRES_HOSTHostname or IP address of the PostgreSQL server.None
AP_POSTGRES_PORTPort number of the PostgreSQL server.None
AP_POSTGRES_DATABASEName of the PostgreSQL database.None
AP_POSTGRES_USERNAMEPostgreSQL user.None
AP_POSTGRES_PASSWORDPostgreSQL password. Generate one with openssl rand -hex 32.None
AP_POSTGRES_USE_SSLConnect to PostgreSQL over SSL.false
AP_POSTGRES_SSL_CASSL certificate (CA) used to connect to PostgreSQL.None
AP_POSTGRES_POOL_SIZEMaximum number of clients in the connection pool.None
AP_POSTGRES_IDLE_TIMEOUT_MSIdle timeout (ms) for pooled PostgreSQL connections.300000

Redis & queue

Redis backs the BullMQ job queue. Connect with discrete fields, a single AP_REDIS_URL, or Sentinel. The queue UI is an optional dashboard for inspecting jobs.
VariableDescriptionDefault
AP_REDIS_TYPEWhere Redis runs: MEMORY (in-process), STANDALONE (dedicated instance), or SENTINEL.STANDALONE
AP_REDIS_URLFull Redis connection URL. When set, all other Redis properties are ignored.None
AP_REDIS_HOSTHostname or IP address of the Redis server.None
AP_REDIS_PORTPort number of the Redis server.None
AP_REDIS_USERUsername used to connect to Redis.None
AP_REDIS_PASSWORDPassword used to connect to Redis.None
AP_REDIS_DBRedis database index to use.0
AP_REDIS_USE_SSLConnect to Redis over SSL.false
AP_REDIS_SSL_CA_FILEPath to the CA file for the Redis server.None
AP_REDIS_SENTINEL_HOSTSComma-separated host:port pairs for Redis Sentinels, e.g. sentinel-1:26379,sentinel-2:26379. Requires AP_REDIS_TYPE=SENTINEL.None
AP_REDIS_SENTINEL_NAMEName of the master node monitored by the sentinels.None
AP_REDIS_SENTINEL_ROLERole to connect to, either master or slave.None
AP_REDIS_FAILED_JOB_RETENTION_DAYSDays to retain failed jobs in Redis.30
AP_REDIS_FAILED_JOB_RETENTION_MAX_COUNTMaximum number of failed jobs to retain in Redis.100000
AP_QUEUE_UI_ENABLEDEnable the queue UI (Redis only).true
AP_QUEUE_UI_USERNAMEUsername for the queue UI. Required when AP_QUEUE_UI_ENABLED is true.None
AP_QUEUE_UI_PASSWORDPassword for the queue UI. Required when AP_QUEUE_UI_ENABLED is true.None
If AP_REDIS_URL is set, all other Redis properties are ignored. The same applies to AP_REDIS_SENTINEL_HOSTS when running in Sentinel mode.

Execution & sandboxing

Controls how flows run: the sandbox mode, per-process memory and concurrency, run timeouts, and the network egress posture for user code. Read Sandboxing before changing AP_EXECUTION_MODE.
VariableDescriptionDefault
AP_EXECUTION_MODESandbox strategy: UNSANDBOXED, SANDBOX_PROCESS, SANDBOX_CODE_ONLY, or SANDBOX_CODE_AND_PROCESS.UNSANDBOXED
AP_CONTAINER_TYPEWhich services run in the container: APP (API only), WORKER (worker only), or WORKER_AND_APP (both).WORKER_AND_APP
AP_WORKER_CONCURRENCYConcurrent jobs a worker processes at once. Each job uses one sandbox instance.5
AP_SANDBOX_MEMORY_LIMITMaximum memory (KB) a single sandboxed engine process can use. Each process runs at most one execution at a time.1048576
AP_SANDBOX_PROPAGATED_ENV_VARSComma-separated environment variables propagated into sandboxed code. For pieces, keep everything in the authentication object so it works across instances.None
AP_FLOW_TIMEOUT_SECONDSMaximum runtime for a single flow run, in seconds.600
AP_TRIGGER_TIMEOUT_SECONDSMaximum runtime for a trigger’s polling, in seconds.60
AP_DEFAULT_CONCURRENT_JOBS_LIMITDefault maximum concurrent runs per project. Can be overridden per project in settings.5
AP_PROJECT_RATE_LIMITER_ENABLEDEnforce per-project rate limits to prevent excessive usage.false
AP_NETWORK_MODEEgress posture for user code. STRICT installs the engine’s in-process SSRF guard, blocking outbound connections to private, loopback, link-local, and cloud-metadata IPs across every Node egress path (axios, fetch, undici, raw http/net). This is best-effort, in-process protection — enforce the real boundary in infrastructure (see Network Security). UNRESTRICTED disables the guard.UNRESTRICTED
AP_SSRF_ALLOW_LISTComma-separated IPs or CIDR ranges that bypass AP_NETWORK_MODE=STRICT, e.g. 10.0.0.5,10.10.0.0/24. Only applies when AP_NETWORK_MODE=STRICT.None

Limits & retention

Caps on file sizes, run-log size, webhook payloads, table sizes, and how long run data is kept. The Cloud values and how these interact are covered in Limits.
VariableDescriptionDefault
AP_EXECUTION_DATA_RETENTION_DAYSDays to retain execution data, logs, and events.30
AP_PAUSED_FLOW_TIMEOUT_DAYSMaximum pause duration for a paused flow, in days. Cannot exceed AP_EXECUTION_DATA_RETENTION_DAYS.30
AP_ISSUE_ARCHIVE_DAYSIssues not updated for this many days are automatically archived.7
AP_MAX_FILE_SIZE_MBMaximum size (MB) for files uploaded in steps or triggers. Larger files are rejected.25
AP_MAX_FLOW_RUN_LOG_SIZE_MBMaximum combined size (MB) of all step inputs and outputs in a single run. Exceeding it ends the run with LOG_SIZE_EXCEEDED.50
AP_FLOW_RUN_LOG_SLICE_THRESHOLD_KBStep outputs larger than this (KB) are offloaded to object storage instead of inlined in the run log.32
AP_FLOW_RUN_LOG_INPUT_TRUNCATE_THRESHOLD_KBStep inputs larger than this (KB) are replaced with a placeholder in the run log; the step still receives the full value at runtime.2
AP_MAX_WEBHOOK_PAYLOAD_SIZE_MBMaximum incoming webhook payload size (MB). Larger payloads are rejected with HTTP 413.25
AP_WEBHOOK_PAYLOAD_INLINE_THRESHOLD_KBWebhook payloads below this (KB) are stored inline in Redis; larger ones are offloaded to file storage to protect Redis memory.512
AP_WEBHOOK_TIMEOUT_SECONDSDefault timeout for synchronous webhooks. Maximum 15 minutes; note Cloudflare caps it at 30 seconds.30
AP_MAX_RECORDS_PER_TABLEMaximum number of records per table.10000
AP_MAX_FIELDS_PER_TABLEMaximum number of fields per table.100

File storage (S3)

Files emitted by steps and triggers are stored in the database or an S3-compatible bucket.
VariableDescriptionDefault
AP_FILE_STORAGE_LOCATIONWhere files are stored: DB (database) or S3 (S3-compatible storage).DB
AP_S3_ENDPOINTEndpoint URL of the S3-compatible service, e.g. https://s3.amazonaws.com. Not required if AWS_ENDPOINT_URL is set.None
AP_S3_BUCKETName of the S3 bucket.None
AP_S3_REGIONRegion of the S3 bucket, e.g. us-east-1. Not required if AWS_REGION is set.None
AP_S3_ACCESS_KEY_IDAccess key ID. Not required when AP_S3_USE_IRSA is true.None
AP_S3_SECRET_ACCESS_KEYSecret access key. Not required when AP_S3_USE_IRSA is true.None
AP_S3_USE_SIGNED_URLSRoute file traffic directly to S3 via pre-signed URLs, bypassing the API server. Keep the bucket private; signed URLs grant temporary access.false
AP_S3_USE_IRSAUse IAM Roles for Service Accounts (IRSA) to authenticate to S3. When true, the access key variables are not required.None

Email (SMTP)

Outbound mail for invitations, notifications, and password resets.
VariableDescriptionDefault
AP_SMTP_HOSTSMTP server host, e.g. mail.example.com.None
AP_SMTP_PORTSMTP server port, e.g. 587.None
AP_SMTP_USERNAMESMTP username.None
AP_SMTP_PASSWORDSMTP password.None
AP_SMTP_SENDER_EMAILEmail address that mail is sent from.None
AP_SMTP_SENDER_NAMESender name shown on outgoing mail.None
SMTP can be configured from the platform admin screen or through these variables. The environment variables are used only when the admin screen has no email configuration, and only when AP_SMTP_HOST, AP_SMTP_PORT, AP_SMTP_USERNAME, and AP_SMTP_PASSWORD are all set. TLS is supported.

Authentication & SSO

Sign-in providers and SCIM provisioning.
VariableDescriptionDefault
AP_GOOGLE_CLIENT_IDGoogle OAuth2 client ID for “Sign in with Google”. Both this and AP_GOOGLE_CLIENT_SECRET must be set for the button to appear; it can no longer be configured from the admin SSO page.None
AP_GOOGLE_CLIENT_SECRETGoogle OAuth2 client secret. Required together with AP_GOOGLE_CLIENT_ID.None
AP_CLOUD_AUTH_ENABLEDUse Activepieces-hosted OAuth2 apps for piece connections. Set to false to disable them.true
AP_SCIM_DEFAULT_PROJECT_ROLEDefault project role for members added via SCIM group sync. One of Admin, Editor, Viewer.Editor

Pieces & flows

How piece metadata is synced, how often scheduled triggers poll, and flow-authoring defaults.
VariableDescriptionDefault
AP_PIECES_SYNC_MODEOFFICIAL_AUTO syncs piece metadata automatically from the cloud; NONE disables syncing.OFFICIAL_AUTO
AP_TRIGGER_DEFAULT_POLL_INTERVALMinutes between checks for new data on pieces with scheduled triggers (e.g. new Google Contacts).5
AP_ENABLE_FLOW_ON_PUBLISHAutomatically enable a flow when a new version is published.true
AP_LOAD_TRANSLATIONS_FOR_DEV_PIECESLoad translations for dev pieces (configured via AP_DEV_PIECES). Affects development mode only.false