For the complete documentation index, see llms.txt. This page is also available as Markdown.

vars

Feature availability

vars is available on:

  • n8n Cloud: Pro, Enterprise

  • Self-hosted: Business, Enterprise

You need access to the n8n instance owner account to create variables.

vars contains all Variables for the active environment. It's read-only: you can access variables using vars, but must set them using the UI.

// Access a variable
$vars.<variable-name>
# Access a variable
_vars.<variable-name>

vars and env

vars gives access to user-created variables. It's part of the Environments feature. env gives access to the configuration environment variables for your n8n instance.

Last updated

Was this helpful?