

Design tokens are the connective tissue between design and development—ensuring consistency, scalability, and a shared language across your product. Since Figma launched Variables in 2023, we’ve had a consistent way to set these values up in our design tools. But while we’ve come a long way with variables, getting those to translate to tokens into your design system workflow, for instance, using zeroheight, isn’t always straightforward.
In this article, I’ll walk you through how to set your variables up in a way that makes sense for your design system and tooling. In later parts, I’ll cover best practices for naming, how to export them into zeroheight, and then converting them into design tokens.
Let’s get started with the architecture!
Many people split their libraries into multiple Figma files to deal with hierarchies, brands, or platforms. While this can be a great way to separate concerns, it does add a layer of complexity to your system.
One of the things that you should think about before getting into setting up your variables is how they’re structured. One of the most common ways to set up design tokens from design systems we’ve worked with is to have:
Suppose you’re not aware of the 'primitives to semantic' way of doing tokens. In that case, it’s an easy way to make everything more straightforward to use for token consumers by providing context, as well as making it easier to maintain and scale. This is because you’re separating concerns and providing context via aliases. blue500 means very little without context. However, color/base/border/primary tells you precisely what that token does. Also, with aliasing, if you ever need to tweak things, you can be very specific in what you’re targeting instead of just changing blue500 and hoping for the best.

Regarding naming, we suggest working with your dev team to use names that make sense across the whole product delivery cycle. We’ve seen Primitives, Semantics, and Component as common ones, but use whatever makes sense for you. Putting a number value also helps make the hierarchy clearer and easier if you create multiple collections for each layer (which we’ll get to).
So, for now, you might end up with something like this:
Main takeaway
First off, we might need some clarity. There are two ways to look at variable types—ways to group variables (ie. color, spacing, typography etc) and the Type property of the variables (ie. string, boolean, number, hex color etc.). For this section, I’m talking about ways to group your variables. There are two different ways you can do this in Figma—using the groupings within a single collection or creating multiple collections for each type.
In terms of groupings, you can easily group your variables by using / . So, if you were dealing with colors in the primitive layer, you might have color/blue/500 , or on the semantic layer, you might have color/base/background/primary. This would then visually organize your variables into groups in Figma and zeroheight, as well as organize them into a good semantic structure in your JSON file.

However, some organizations have huge sets of variables, so will want to use these groupings, but break out the bottom layer into separate collections. So your semantics layer might have collections named:
The one area we wouldn’t suggest splitting into multiple collections is primitives. This is purely to keep things more manageable, and to not have to reference a million different files on the code side (although you could also set up the scripting to cover off consolidation).
Another thing to consider with this is if you’re using modes (covered in the next section). If you have multiple collections, with multiple modes in each one, you may have to manually apply the different modes for different collections, even if your modes are all named the same. This is primarily an issue in Figma, as it’s not much of a problem when it comes to zeroheight or code.
Main takeaway
One of the things that Figma offers within variables is the use of ‘modes’. These allow you to have switchable styles within a collection, that you can switch between in the UI to pull in different sets of variables.
We’ve seen folks use these modes for different things: primary/secondary/tertiary (terrible idea), light/dark/high contrast, web/mobile, brand1/brand2/brand3. However, one super important thing to remember is that these modes are restricted depending on what plan you’re on. If you’re anything below enterprise on Figma, there are only 4 modes available per collection, and enterprise has a limit of 40 modes per collection.
If we were setting up our tokens today using modes, we would suggest using modes for a single thing. For us, color modes(ie light, dark, high contrast etc) make the most sense and should be defined in a single collection level. Platforms and brands would sit within separate collections, most likely at the semantic and/or component level.

One of the most important things when dealing with modes in Figma is to only define them at a single level. The mode setting doesn’t cascade, so if you have multiple levels of modes, you will need to define these at multiple levels. Similarly, you should remember when deciding how you split your variables out into collections, that you have to set the mode for every collection. So if you have 01 Colors, 01 Typography, 01 Shadows etc., you will need to specify the mode for every collection when you’re applying them at a frame or component level. Obviously, if you can make it as easy as possible for the user that is key, so limiting the amount of collections you have can help here.

Main takeaway
We’ve touched on it already, but what do you do if you’re handling a global system that applies to a myriad of brands? Instinctively, I’d suggest separating out concerns into multiple libraries.
To keep things tidy, some people split out their collections at all levels (primitive, semantics, components). This decision comes down to what you’re working with. If, for example, you have different shades of blue across multiple brands, you could either split out your collections into multiple collections (ie 00 Brand 1 and 00 Brand 2) or keep it to one collection and use the folder groupings to differentiate (ie 00 Primitives and base/color/brand1/blue/500).
One consideration to make is how big these files are going to be. In reality, it’s probably not going to make a ton of difference if you have 50 or 500 variables in a file. Again, the aim here is maintainability.
When it comes to semantic and component levels, you will want to split these out into multiple collections. Depending on how similar your brand experiences are at a component level, you might get away with only having brand variables defined at a semantic level. However, if the components used in each brand are wildly different, you might want to have different collections on both levels.
Because there are so many ways to cut the cake when it comes to setting up multi-brand design systems, it's worth looking at what others have done. Romina Kavcic has pulled together a good collection of case studies of how big companies set their variables and tokens up.
PART THREE: Automating your token delivery
