On this page
- Quick steps
- Which variable type should you pick?
- How to set up Figma variables: collections and modes
- Scoping and Hide from publishing
- How to create groups in Figma variables
- Figma shortcut to duplicate a variable
- How to delete Figma variables
- How to remove used variables in Figma
- Moving variables to another file
- FAQ
Quick steps
Open the Variables tab
In a Figma Design file, click Variables in the navigation bar on the left side of the editor.
Create or pick a collection
Variables live in collections. Use More options → Create collection to start one, for example Colors or Spacing. A collection holds up to 5,000 variables.
Click + Create variable
Choose the type: color, number, string or boolean. Timing and easing are for Figma Motion.
Name it and set the value
Type a name. Use slashes, like color/text/primary, to put it in a group automatically. Then enter the value.
Set scoping if needed
Open the Edit variable dialog to limit where the variable appears, or tick Hide from publishing if it should stay local to the file.
Apply it to a layer
Select a layer, open the matching property in the right sidebar and pick the variable from the picker.
Which variable type should you pick?
The type decides which properties a variable can attach to. If you pick the wrong one, the variable won't show up where you expect it.
- Color: fills, strokes, effects and gradient stops.
- Number: sizes, gap, padding, corner radius, opacity and other numeric fields.
- String: text content and font properties.
- Boolean: layer visibility, applied by right-clicking the eye icon in the Appearance section. See how to show and hide layers with a boolean variable.
- Timing and easing: animation values for Figma Motion only.
How to set up Figma variables: collections and modes
A collection is a set of related variables. A common setup is separate collections for primitives (the raw palette and spacing scale) and semantic tokens (text/primary, surface/default) that point at the primitives. Variables can reference other variables, so a semantic color can alias a primitive instead of repeating the hex value.
Each collection can have modes, such as Light and Dark or Compact and Comfortable. Every variable in the collection gets one value per mode. The full setup for theming is in how to change variable modes and build dark mode.
Scoping and Hide from publishing
Open a variable's Edit variable dialog to set its scoping, which limits the properties it appears for. Scope spacing numbers to gap and padding, and radius numbers to corner radius, so designers don't see forty numbers in every field. Tick Hide from publishing for primitives that should only be referenced by other variables, not applied directly in other files.
How to create groups in Figma variables
There are two ways. Name variables with slashes, like spacing/sm and spacing/md, and Figma groups them under spacing. Or select several variables in the table, right-click and choose New group with selection. Groups show in the sidebar of the Variables view and keep long lists readable.
Figma shortcut to duplicate a variable
Select a variable in the table and press ⇧Enter (Shift+Enter) to duplicate it. This is the fastest way to build a scale: make radius/sm, duplicate it, rename the copy to radius/md and change the value. Figma doesn't document a keyboard shortcut for opening the Variables tab itself, so click it in the left navigation.
| Action | Mac | Windows |
|---|---|---|
| Duplicate selected variable | Mac⇧Enter | WindowsShiftEnter |
| Open the Actions menu | Mac⌘K | WindowsCtrlK |
How to delete Figma variables
Right-click the variable and choose Delete variable. To remove a whole set, delete the collection; that deletes every variable in it. Check where a variable is used before you delete it.
How to remove used variables in Figma
A common forum complaint (a thread with over 100 replies) is "ghost" variables: entries that still appear under used variables or in the Page section's modes after the collection or component that brought them in is gone. The accepted answer from Figma Community Support gives two steps:
- Open the Actions menu (⌘K / Ctrl+K) and run Detach deleted variables. This clears most leftovers in one go.
- If some remain, they're still used somewhere, often inside components or deleted color styles. Find those layers and detach or replace the variable by hand.
Moving variables to another file
The standard way to share variables is to publish them in a library. When that's not an option, for example a one-off copy between two files or restoring a backup, you can export and import JSON natively (see how to export Figma variables) or use a plugin that moves whole collections with a preview of what gets created or overwritten.
If a variable you just made doesn't appear in a property picker, the cause is usually its type or scoping. The fixes are in Figma variables not showing.
Ranked listThe best Figma design token and variables plugins in 2026Frequently asked questions
Where are variables in Figma now?
Click the Variables tab in the left navigation bar of a Figma Design file. You no longer have to deselect everything and look in the right sidebar.
How many variables can a Figma collection hold?
Up to 5,000 variables per collection. If you need more, split them across several collections, such as primitives and semantic tokens.
Can I use variables on the free plan?
Yes. Any plan can create and apply variables, as long as you have edit access to the file. Publishing them in a library and prototyping with them need a paid plan.
What's the difference between variables and styles?
A variable stores one value and can have a different value per mode. A style bundles several values, like a whole text style, and can't reference other styles. Styles can use variables inside them. See the guide to Figma styles for when to use which.
More in Variables & styles
- How to Export Figma Variables to JSON (and CSS, Tailwind or CSV)Export Figma variables to JSON natively, convert them to CSS or Tailwind with Style Dictionary, and move variables between files with Variable Master.
- Figma Variables Not Showing? Here's Why and How to Fix ItFigma variables now open from the Variables tab in the left nav. If one won't appear in a picker, check its type, scoping and library. Mode switch fixes too.
- How to Toggle a Boolean Variable to Show and Hide Layers in FigmaBind a boolean variable to layer visibility, then toggle it on click with Set variable and a not expression. Plus why boolean variables stop working in Figma.
- How to Change Variable Modes in Figma and Build Dark ModeSet up Light and Dark modes in one Figma color collection, switch a frame or page with Apply variable mode, and fix modes that won't change in prototypes.
- How to Create Text Styles and Color Styles in FigmaCreate text and color styles in Figma, organise them into folders, edit or delete them, fix styles not showing in other files, and know when to use variables.
- How to Create and Publish a Library in FigmaCreate a Figma library: build components, styles or variables in one file, then Assets → Libraries → Publish. Plan and seat rules, drafts, hiding assets.
- How to Make Design Specs in FigmaWhat a Figma design spec should include, how to build a component spec template by hand, what Dev Mode already covers, and how to generate specs with Autospec.
- How to Generate All Component Variants in FigmaFigma shows only the variants you draw. Here's how to lay out every combination of variant, boolean and nested props as a matrix, by hand or with Instancer.
- How to Make a Skeleton Loader in FigmaHow to design a skeleton loader in Figma: grey blocks with auto layout, a component with variants, a Smart Animate shimmer, and a plugin that converts frames.
