Variables Cheatsheet

Last Updated December 11, 2025

What Are Variables?

Variables store information about a user that exists on the web page, such as their role, department, access level, email address, or user ID. WalkMe reads these values directly from the page but does not modify or change any data in your application.

How WalkMe Use Variables

Variables allow WalkMe to understand who the user is and what type of experience they should receive.

Segmentation

Variables help identify user attributes such as role, permission level, or department. WalkMe uses this information to show only the most relevant guidance to each user.

Reports

Variables that represent unique identifiers, such as email or ID, allow WalkMe to generate usage reports and track completion of key processes for specific users.

How To Create a Variable

WalkMe can read any variable that is accessible on the page and attached to the global window object. A developer can expose existing values from your system by assigning them to window, making them readable by WalkMe.

A WalkMe-readable variable must meet two conditions:

  • It must be accessible in the browser console or on the page level
  • It must be present on every page where it will be used

To create a variable, your Development or IT team should know:

  • The name of the variable
  • The values the variable will contain (for example: Admin, Sales, Marketing, Manager)

Example

Declare a variable using a value already available on the page:

var userRole = user.getUserRole()

Attach it to the window object so WalkMe can read it:

window.userRole = userRole

Once the variable exists globally, WalkMe can use it for segmentation or tracking.

Configuring Variables in WalkMe

If the variable will be used for analytics or onboarding tasks (UUID configuration), you must configure it in the Admin Center.

Steps:

  1. Open the Systems pages in the Admin Center
  2. Select the system you want to configure
  3. Go to Data Settings
  4. Select Unique user settings (UUID)
  5. In the User identifier defined by dropdown, select Variable
  6. Enter the variable name
  7. Select the expected format (Email, GUID, Integer, or Custom Regex)

Unique User Settings (UUID)

Note

If a variable is used only for segmentation, no configuration is required. However, variables configured here will also be available for segmentation.

Using Variables for Segmentation

To use a variable inside a segment rule:

  1. Select Manage segments
  2. Create a new segment or edit an existing one
  3. Select the pencil icon to edit segment rules
  4. Select Add Rule
  5. In Rule Type, select User Data, then select Variable
  6. Type your variable name
  7. Choose an operator and enter the value you want to target

Was this article helpful?

Thanks for your feedback!

Be part of something bigger.

Engage with peers, ask questions, share ideas

Ask the Community
×