Every product team eventually gets the request: "Can we add dark mode?" It sounds like a weekend job. Swap white for black, black for white, ship it.
Then the screens come back looking wrong. Brand colours vibrate against black. Cards disappear into the background. Shadows vanish. Text feels harsh at night instead of easier. Users switch it on once and quietly switch it off again.
Dark mode isn't inverted colours. It's a second theme with its own rules, and it deserves the same care as the light one. Here's how I approach it.
Decide why you're building it
Before designing anything, I ask what dark mode is for in this product. The answer changes the priorities.
- Comfort in low light. Imagine a parenting app opened in a dark bedroom at 2 a.m., or a reading app used in bed. Here, dark mode is close to a core feature, and the goal is low glare and calm. On Pukaar.ai, one of our design rules was that the interface assumes it's 2 a.m. That rule was about one handed use and big tap targets, but it also made me think hard about glare in a dark room.
- User preference. Many people simply set their phone to dark and expect apps to follow. Here, the goal is matching the system setting without anything feeling broken.
- Long sessions. Developer tools, trading screens and editing apps where people stare for hours.
- Battery. On OLED screens, darker pixels can use less power. It's a nice side effect, but I wouldn't make it the main reason.
What I'd avoid: building dark mode as a style statement ("it looks premium") while the light theme still has unfixed basics. Two half finished themes are worse than one good one.
And always give people a choice: follow the system, light or dark. Never force dark on everyone.
Pick dark surfaces, not pure black
Pure black (#000000) with pure white text looks dramatic in a mockup, but the high contrast can feel harsh in long reading sessions, and it leaves you no room to show depth. Material Design's guidance for dark themes recommends a dark grey (#121212) as the base surface, and many products use something in that range.
I usually set up a small ladder of surfaces:
- Background: the darkest grey, for the app canvas
- Surface 1: slightly lighter, for cards and lists
- Surface 2: lighter again, for sheets, menus and dialogs
- Surface 3: the lightest, for things that float above everything (tooltips, snackbars)
A tiny tint of the brand colour in those greys (a blue grey, a warm grey) often feels more polished than neutral grey. Keep it subtle.
Watch out
Don't make the surface steps too close together. If you can't tell Surface 1 from Background on a budget phone at low brightness, the ladder isn't doing its job.
Show depth with lightness, not shadows
In light mode, a card lifts off the page with a shadow. On a dark background, shadows barely show. So dark themes flip the logic: surfaces closer to the user get lighter. Material Design describes exactly this approach, where higher surfaces are shown with lighter colour.
In practice:
- Higher layers use the lighter steps of your surface ladder
- Keep a soft shadow if you like, but don't rely on it alone
- Use thin, low contrast borders (a light grey at low opacity) to separate cards that sit on the same level
- Dim the content behind modals with a scrim so the active layer stands out
If you skip this, every card merges into the background and the screen reads as one flat slab.
Rework colours instead of reusing them
This is where most teams go wrong. Brand colours chosen for white backgrounds rarely work on dark ones as they are. If your first dark build looks off, this grid usually explains why:
| Symptom | Likely cause | Fix |
|---|---|---|
| Brand colour glows or vibrates | Saturated accent reused from light mode | Make a lighter, less saturated dark accent |
| Cards vanish into the background | Depth shown only with shadows | Lighter surface steps for higher layers, subtle borders |
| Text feels harsh at night | Pure white on pure black | Off white text on a dark grey base |
| Error states hard to spot | Light mode red reused on dark grey | A dedicated dark red, plus an icon and label |
| Illustrations look like glowing boxes | White backgrounds baked into images | Transparent or dark friendly versions |
Desaturate and lighten accents
A saturated brand green or purple that looks great on white can glow and vibrate on dark grey. I create a dark mode version of each accent: a little lighter and a little less saturated. It stays recognisably on brand but stops shouting.
Soften text
Pure white text on dark grey can be tiring. I use an off white for body text and step down for secondary text:
- Primary text: close to white, but not pure #FFFFFF
- Secondary text: a mid grey with enough contrast for reading
- Disabled text: clearly dimmer, but still legible as "this exists"
Check status colours
Reds, greens and yellows for errors, success and warnings need their own dark versions too. A dark red that works on white can become nearly invisible on dark grey. And as always, don't rely on colour alone. Keep icons and labels on every status.
Mind images and illustrations
Bright illustrations with white backgrounds look like glowing rectangles in dark mode. Provide dark friendly versions, use transparent backgrounds, or slightly reduce brightness. Logos often need a light version.
For more on picking colour and type in general, see choosing colour and typography for a product UI.
Check contrast, every time
Dark mode is not an excuse to drop accessibility. WCAG's contrast requirements apply in both themes: for AA, at least 4.5:1 for normal text and 3:1 for large text and for important UI components such as input borders and icons. The full guidelines live at the W3C WCAG overview.
Common dark mode contrast failures I see:
- Grey secondary text that's fine on white but too dim on dark grey
- Placeholder text and input borders that disappear
- Disabled buttons that look identical to the background
- Brand coloured links that fall below 4.5:1 on dark surfaces
I run a contrast checker on every text and background pair in both themes before handoff. It takes an hour and saves a lot of complaints. My accessibility starter covers the rest of the basics.
Note
Contrast checkers measure colour pairs, not glare. A pair can pass 4.5:1 and still feel uncomfortable in a dark room, so look at the screens at night on a phone too.
Also test on real phones, not just your laptop. Budget Android screens, which many Indian users rely on, often have lower brightness and different colour rendering. A grey that looks fine on a calibrated monitor can vanish on a ₹10,000 phone at 30% brightness.
Build it as a theme in Figma
Doing dark mode by duplicating every screen and recolouring it by hand is a maintenance nightmare. Set it up as a theme from the start.
My setup in Figma:
- Primitives: the full grey ramp and accent ramps, including the lighter, less saturated dark mode accents.
- Semantic tokens: names by role, like
color/bg/canvas,color/bg/surface-1,color/text/primary,color/border/subtle,color/feedback/error. - Two modes: Light and Dark. Each semantic token points to a different primitive in each mode.
- Components only use semantic tokens. Switch the mode on a frame and the whole screen changes.
That's the same two layer structure I describe in setting up a design system in Figma. If you build components this way from day one, adding dark mode later becomes a token mapping job instead of a redesign.
Tip
Name tokens by role from day one, even if dark mode isn't on the roadmap yet. Renaming
green-500tocolor/feedback/successacross a whole file later is far more painful than doing it at the start.
Then design a few key screens in dark mode by hand to tune the details: the dashboard, a form with errors, a modal, an empty state. Tokens get you most of the way. Your eyes do the rest.
Work with us
Want a team to design it with you? Our UI/UX design agency for startups and SaaS takes products from research to developer handoff.
Key takeaways
- Know why you're adding dark mode, and let people choose system, light or dark.
- Use dark grey surfaces instead of pure black, with a ladder of lighter levels for depth.
- Create dark versions of brand, text and status colours instead of reusing light ones.
- Check WCAG contrast in both themes and test on real budget phones.
- Build dark mode as a token based theme in Figma, not as duplicated screens.
Thinking about adding dark mode?
Done well, dark mode feels like the product was always meant to look that way. Done badly, it feels like a filter someone forgot to finish.
If you're planning a dark theme or want your design system set up so themes are easy later, tell me about your project. You can also ask Sage, the assistant on my site, about how I work.