header-logo
Learn how to use Wix to build your site and business.
Design and manage your site using intuitive Wix features.
Manage subscriptions, plans and invoices.
Run your business and connect with members.
Learn to purchase, connect or transfer a domain to your site.
Get tools to grow your business and web presence.
Boost your visibility with SEO and marketing tools.
Get advanced features to help you work more efficiently.
Find solutions, learn about known issues or contact us.
placeholder-preview-image
Improve your skills with our courses and tutorials.
Get tips for web design, marketing and more.
Learn to increase organic site traffic from search engines.
Build a custom site using our full-stack platform.
Get matched with a specialist to help you reach your goals.
placeholder-preview-image
In this article
  • Adding a local variable to your automation
  • FAQs

Wix Automations: Setting Up and Using Local Variables

4 min
In this article
  • Adding a local variable to your automation
  • FAQs
Before you begin:
This article is intended for advanced users. Creating advanced automations using the local variable step requires familiarity with customizing your data with a formula field
Local variables let you create a placeholder for information you use repeatedly in your automation. This gives you the flexibility to manipulate your data and reuse it in conditions or actions.
Instead of adding or calculating the same details over and over, you set up a local variable once and reuse it as many times as necessary. If you ever want to update the variable, you only need to do so in one place and it updates throughout your automation.
Screenshot of a full automation flow using variables.

Adding a local variable to your automation

Add a local variable to your automation by adding a new step. To work with variables effectively, make sure to add them before the point in the flow where you plan on using them. 
For example, you can add a local variable right after selecting a trigger so it's available to use in all of the steps that follow (e.g. condition, action). 

To add a local variable to an automation:

  1. Go to Automations in your site's dashboard.
  2. Create a new automation or edit an existing automation.
  3. Click to add a step.
  4. Click Custom value.
  5. Click Local variable.
  6. Add your variable info:
    1. Variable name: Add an easily identifiable name.
    2. Data type: Select the appropriate data type (e.g. number, text, boolean).
    3. Value: Set the variable's value. You can also click Customize to create a complex calculation made up of properties, functions and values. 
  7. (Optional) Click + Add Variable to add another variable.
  8. Click Apply.
  9. Continue building your automation as needed. 
Screenshot of a configuration of a local variables step.

FAQs

Click a question below to learn more about using local variables.

Helpmate

Hello

Need a bit more guidance?
Summary of this article
Unlock personalized helpLog in to get the most out of Helpmate.