Environment File
Airweave uses environment variables for configuration. Copy.env.example to .env and customize:
start.sh script automatically generates required secrets if they’re missing.
Required Variables
These variables must be set for Airweave to function:Encryption & Security
Base64-encoded 32-byte key for encrypting sensitive data (API keys, OAuth tokens)Auto-generated by
start.sh using:Secret for OAuth state parameter signingAuto-generated by
start.sh using:Embedding Configuration
Dense embedding model for semantic searchOptions:
openai_text_embedding_3_small- Up to 1536 dimensions (requiresOPENAI_API_KEY)openai_text_embedding_3_large- Up to 3072 dimensions (requiresOPENAI_API_KEY)mistral_embed- Fixed 1024 dimensions (requiresMISTRAL_API_KEY)local_minilm- Fixed 384 dimensions (requires local embeddings service)
openai_text_embedding_3_smallVector dimensions matching the chosen embedderMust match your DENSE_EMBEDDER:
- OpenAI small:
1536 - OpenAI large:
3072 - Mistral:
1024 - Local MiniLM:
384
1536Changing this after data is indexed requires re-indexing all documents.
Sparse embedding model for keyword search (BM25)Options:
fastembed_bm25- Fast BM25 implementation (no API key needed)
fastembed_bm25Database Configuration
PostgreSQL
PostgreSQL server hostnameDocker Compose:
localhost (mapped port)Kubernetes: Service name (e.g., postgres-service)PostgreSQL server port
PostgreSQL username
PostgreSQL password
PostgreSQL database name
SSL mode for PostgreSQL connectionOptions:
disable, allow, prefer, require, verify-ca, verify-fullRedis
Redis server hostname
Redis server port
Storage Configuration
Airweave supports multiple storage backends for file attachments:Backend Selection
Storage backend typeOptions:
filesystem- Local or PVC storage (default for local/test)azure- Azure Blob Storage (default for dev/prd with Azure)aws- AWS S3 or S3-compatible storagegcp- Google Cloud Storage
ENVIRONMENT:localortest→filesystemdevorprd→azure
Filesystem Storage
Local filesystem path for file storageDevelopment:
./local_storage (relative to project root)Kubernetes: /data/airweave-storage (PVC mount point)Debugging tip: Use /tmp/airweave_local_storage to avoid uvicorn reload issuesSkip Azure Blob Storage initialization (set by
start.sh)Azure Blob Storage
Azure Storage account nameExample:
airweavestorageAzure Blob container name
Optional path prefix within container
AWS S3 Storage
S3 bucket nameExample:
airweave-productionAWS regionExample:
us-east-1Optional path prefix within bucket
Custom S3 endpoint for MinIO, LocalStack, etc.Example:
http://minio:9000AWS access key (or use IAM roles in production)
AWS secret key (or use IAM roles in production)
GCP Cloud Storage
GCS bucket name
GCP project ID
Optional path prefix within bucket
Authentication
Local Authentication
Enable authentication systemDevelopment:
false (single-user mode)Production: true (requires Auth0 or similar)Default admin user email (when
AUTH_ENABLED=false)Default admin password
Auth0 Configuration
Required when
AUTH_ENABLED=trueAuth0 tenant domainExample:
your-tenant.auth0.comAuth0 API audience identifierExample:
https://api.airweave.aiNamespace for custom claims in Auth0 tokensExample:
https://airweave.aiTemporal Configuration
Temporal server hostname
Temporal gRPC port
Temporal namespace for workflows
Task queue name for sync workers
Vespa Configuration
Vespa server URL (without port)
Vespa document API port
Embeddings Services
Local Embeddings
Local embedding service URLDocker:
http://text2vec-transformers:8080Only used when DENSE_EMBEDDER=local_minilmAPI Keys
OpenAI API key for embeddings and LLM featuresRequired for:
openai_text_embedding_3_smallopenai_text_embedding_3_large- File content extraction
- Natural language search
Anthropic API key (for future features)
Mistral API key for embeddingsRequired for:
mistral_embed embedderWebhook Configuration (Svix)
Svix webhook server URL
Secret for signing Svix JWTs (must be ≥32 bytes)Default:
default_signing_secret_change_me!Optional authentication token for Svix API
Application Settings
Environment
Deployment environmentOptions:
local, test, dev, prdAffects:- Default storage backend
- Logging verbosity
- Error reporting
Enable development mode featuresWhen true:
- Hot reload enabled
- Verbose logging
- CORS relaxed
trueSpecial mode for Cursor IDE integration
Logging
Python logging levelOptions:
DEBUG, INFO, WARNING, ERROR, CRITICALDatabase Management
Automatically run database migrations on startupRecommended:
true for most deploymentsSet to false only if managing migrations externallySynchronize database state on startup
Features
Enable AI code summarization for developer tools
Enable Stripe payment integration (for managed hosting)
URLs
Full public URL for the API (for webhooks and OAuth callbacks)Example:
https://api.yourdomain.comFull public URL for the frontendExample:
https://app.yourdomain.comComma-separated list of additional CORS originsExample:
https://custom-ui.com,https://staging.example.comFrontend
Port for frontend UI
Miscellaneous
Project display name
Optional secondary OCR provider for document processing
Test Configuration
These variables are only used for integration tests:AWS S3 Tests
S3 bucket for storage backend tests
AWS region for tests
GCP Storage Tests
GCS bucket for tests
GCP project for tests
Azure Blob Tests
Azure storage account for tests
Azure container for tests
Configuration Examples
Development (Local Embeddings)
.env
Production (OpenAI Embeddings + Cloud Storage)
.env
Kubernetes (Mistral Embeddings + GCP Storage)
.env
Security Best Practices
Rotate secrets regularly
Generate new values for:
ENCRYPTION_KEYSTATE_SECRETSVIX_JWT_SECRET- Database passwords
Use secrets management
In production, load secrets from:
- Kubernetes: Secrets, External Secrets Operator
- AWS: Secrets Manager, Parameter Store
- Azure: Key Vault
- GCP: Secret Manager
- HashiCorp: Vault
Use managed identity
For cloud storage, prefer:
- AWS IAM Roles for Service Accounts (IRSA)
- Azure Managed Identity / Workload Identity
- GCP Workload Identity
Enable SSL/TLS
- Set
POSTGRES_SSLMODE=require - Use HTTPS for all external URLs
- Configure TLS certificates for Redis if exposed
Troubleshooting
Application won't start - missing embedding variables
Application won't start - missing embedding variables
Error:
DENSE_EMBEDDER, EMBEDDING_DIMENSIONS, and SPARSE_EMBEDDER must all be setSolution: Set all three variables in .env:Dimension mismatch error
Dimension mismatch error
Error: Vespa schema expects different dimensionsSolution:
- Ensure
EMBEDDING_DIMENSIONSmatches yourDENSE_EMBEDDER - Recreate Vespa deployment:
Storage backend not working
Storage backend not working
Check:
- Credentials are correct (access keys, service account)
- Bucket/container exists and is accessible
- Permissions allow read/write operations
Database connection failures
Database connection failures
Debug:Common issues:
- Wrong host/port
- Incorrect credentials
- SSL mode mismatch
- Database not initialized
Next Steps
Deploy with Docker
Get started with Docker Compose deployment
Scale with Kubernetes
Production deployment on Kubernetes
Configure Connectors
Set up data source integrations
Advanced Features
Customize embeddings, chunking, and transformers