Neutral colors
This guide explains the process and reasoning behind modifying the neutral color palette within the shadcn/ui kit for Figma.
Instructions
You can easily change the neutral colors (such as background, foreground, border, input, muted, etc.) of your components by switching from Neutral to other neutral color families.
Simply select the Neutral color variables in the Theme collection and replace the Neutral color references with your preferred Tailwind color space alternatives such as Slate, Stone or Gray.
Why use different neutral color hues?
Tailwind CSS offers a variety of neutral color palettes (like slate, gray, zinc, neutral, and stone) because a single "gray" rarely fits all design needs. These different neutral palettes aren't just varying shades of pure gray; they are subtly tinted towards other hues, providing designers with more nuanced options. Here's why Tailwind provides them and why you'd choose one over another:
Harmonizing with primary colors
Pure, desaturated gray can sometimes feel stark, cold, or clash with your brand's primary colors. For instance, a cool gray might feel out of place with warm brand colors (reds, oranges, yellows). Tinted neutrals offer better complementation:
- stone, neutral, zinc: These often have warmer, slightly brown/yellow/reddish undertones. They pair well with warmer brand colors, creating an organic, earthy, or traditional feel. Neutral aims for strong balance.
- slate, gray: These often have cooler, slightly blue/purple undertones. They work well with cooler brand colors (blues, greens, purples), evoking a modern, sleek, or industrial feel. Gray is the most desaturated, closest to a "true" gray.
Conveying specific moods or tones
The subtle tint of a neutral palette significantly influences the overall feeling of your design:
- Warm neutrals (e.g., stone) can make a design feel more approachable, comforting, or natural.
- Cool neutrals (e.g., slate)can make a design feel more sophisticated, professional, or high-tech.
- Balanced neutrals (e.g., neutral, zinc) aim for a versatile, middle-ground feel.
Adding subtle depth and richness
Using only pure grays can sometimes make a design look flat or "muddy," especially with many shades. Tinted neutrals introduce a subtle complexity and richness, making the design more visually interesting without being overtly colorful.
Providing design flexibility
Multiple neutral options give designers the flexibility to fine-tune their color schemes and achieve their desired aesthetic. It's about offering choices to better serve diverse design requirements.
How to choose which neutral palette to use
- Consider your brand colors: Pick a neutral palette that complements and enhances your primary color palette. If your brand uses a vibrant blue, `slate` might be a good choice. If it uses a warm terracotta, `stone` could work well.
- Think about the desired mood: What feeling do you want your interface to evoke? Serious and corporate? Friendly and organic?
- Experiment: The best way is often to try out a few different neutral palettes in your design to see which one "feels" right. Tailwind's utility-first nature makes this easy to swap out.
- Stick to one (mostly): While you have options, it's generally good practice to pick one primary neutral palette for your project and use it consistently for visual harmony. You might occasionally use another for a specific accent if needed, but your base should be consistent.
- In essence, Tailwind's diverse neutral palettes acknowledge that "neutral" isn't a one-size-fits-all concept in design. The subtle tints offer a sophisticated way to create harmonious, mood-appropriate, and visually rich interfaces.