OpnForm uses two .env files for configuration: one for the Laravel backend located in the api directory, and one for the Nuxt front-end located in the client directory.

Backend Environment Variables

The following environment variables are used to configure the Laravel application (OpnForm’s API).

Dedicated guides

There are dedicated configuration pages available for more detailed setup instructions on specific topics:

Other Environment Variables

Configuration Environment Variables

Variable NameDescription
JWT_TTLTime to live for JSON Web Tokens (JWT).
JWT_SECRETSecret key used to sign JWTs.
H_CAPTCHA_SITE_KEYSite key for hCaptcha integration.
H_CAPTCHA_SECRET_KEYSecret key for hCaptcha integration.
OPEN_AI_API_KEYAPI key for accessing OpenAI services.
UNSPLASH_ACCESS_KEYAccess key for Unsplash API.
UNSPLASH_SECRET_KEYSecret key for Unsplash API.
GOOGLE_CLIENT_IDClient ID for Google OAuth.
GOOGLE_CLIENT_SECRETClient secret for Google OAuth.
GOOGLE_REDIRECT_URLRedirect URL for Google OAuth.
GOOGLE_AUTH_REDIRECT_URLAuthentication redirect URL for Google OAuth.
GOOGLE_FONTS_API_KEYAPI key for accessing Google Fonts.
FRONT_URLPublic facing URL of the front-end.
FRONT_API_SECRETShared secret with the front-end.

User Options Environment Variables

Variable NameDescription
ADMIN_EMAILSComma-separated list of admin email addresses.
TEMPLATE_EDITOR_EMAILSComma-separated list of template editor emails.
EXTRA_PRO_USERS_EMAILSComma-separated list of extra pro user emails.
MODERATOR_EMAILSComma-separated list of moderator email addresses.

Front-end Environment Variables

Front-end Environment Variables

Variable NameDescription
NUXT_PUBLIC_APP_URLPublic facing URL of the Nuxt application.
NUXT_PUBLIC_API_BASEBase URL for the Laravel API.
NUXT_PUBLIC_H_CAPTCHA_SITE_KEYSite key for hCaptcha integration on the front-end.
NUXT_API_SECRETShared secret key between Nuxt and Laravel backend.

The easiest way to get started with OpnForm is through our official managed service in the Cloud. It takes just 1 minute to try out the builder for free, with high availability, backups, security, and maintenance all managed for you.