Variables

Variables let you define key-value pairs that your application will use at build time and runtime. They’re commonly used for setting environment configuration or secrets, and are always encrypted, scoped, and secure by default.

What variables are

Variables are injected into your application as environment variables. You can use them to define values such as tokens, API URLs, feature flags, or credentials — without hardcoding anything in your codebase.

  • Encrypted at rest and during usage.

  • Application-specific and not shared across services.

  • Injected automatically at build and runtime.

You can add, edit, or delete them at any time.

When you can add variables

Variables can be defined in two moments:

  1. During application setup: Add variables as part of the initial configuration before the first deployment.

  2. After the application is created: Add or change variables at any time once the app is running. Any update will apply to the next deployment.

How to manage variables

To manage variables for any application:

  1. Open your application in Dash.

  2. Click on the 3 dots icon button.

  3. Select the Variables option.

  4. You can:

    • Add a new variable by setting a name and a value.

    • Edit an existing variable to change its value.

    • Delete a variable if it’s no longer needed.

All changes will take effect in the next deployment.

Recommendations

To keep your application secure and stable:

  • Never commit a real .env file to your repository.

  • Never expose secrets directly in your code.

  • Handle missing non-critical variables gracefully (e.g., use fallbacks or warnings).

  • Clean up unused variables when they’re no longer needed.

Using variables helps you keep sensitive data secure and makes your deployments more flexible and portable — with no extra setup needed.

Updated on