Production Environment
Environment Variables
Creating Environment Variables
You need to create an .env file in your project root directory and add the following environment variables:
# ASTRIA (AI service)
# Get API key - https://www.astria.ai/users/edit#api
ASTRIA_API_KEY = your-astria-api-key
# Test mode is controlled from the Admin Panel > Settings.
# No env var needed.
# SUPABASE (Database service)
# Globally get Supabase details from your your hosted server running supabase - https://supabase.com/
# For production environment, you can use the following values:
NEXT_PUBLIC_SUPABASE_URL = your-supabase-url
NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY = your-supabase-publishable-key
SUPABASE_SECRET_KEY = your-supabase-secret-key
SUPABASE_ANON_KEY = your-supabase-publishable-key
SUPABASE_URL = your-supabase-url
# VERCEL BLOB (Image storage service)
BLOB_READ_WRITE_TOKEN = your-vercel-blob-read-write-token
# RESEND (Email service)
RESEND_API_KEY = your-resend-api-key
RESEND_SENDER_EMAIL = your-resend-sender-email
# STRIPE (Payment service)
STRIPE_SECRET_KEY = your-stripe-secret-key
STRIPE_WEBHOOK_SECRET = your-stripe-webhook-secret
NEXT_PUBLIC_STRIPE_IS_ENABLED = true # set to true to enable Stripe payments
# PAYPAL (Payment service)
NEXT_PUBLIC_PAYPAL_CLIENT_ID = your-paypal-client-id
PAYPAL_CLIENT_SECRET = your-paypal-client-secret
# RAZORPAY (Payment service)
NEXT_PUBLIC_RAZORPAY_KEY_ID = your-razorpay-key-id
RAZORPAY_KEY_SECRET = your-razorpay-key-secret
# GOOGLE ANALYTICS (Analytics service)
NEXT_PUBLIC_GOOGLE_ANALYTICS_ID = your-google-analytics-id-source-link
NEXT_PUBLIC_GOOGLE_ANALYTICS_ID_VALUE = your-google-analytics-id-value
# DEPLOYMENT
DEPLOYMENT_PROVIDER = vercel # or replit
ASTRIA_WEBHOOK_URL = your-astria-webhook-url # e.g. localhost:3000 (domain without https://)
# APP URL
NEXT_PUBLIC_APP_URL = your-app-url # e.g. http://localhost:3000This is how your project root directory should look after creating the .env file: