DESIGN.md: Google's Open-Source Format for Giving AI Coding Agents a Design System

DESIGN.md by Google Labs Code is an open-source format specification for describing visual identity to AI coding agents. 20.8k GitHub stars. Learn how it bridges design systems and AI code generation with YAML tokens and prose-based constraints.

  • ⭐ 20800
  • Updated 2026-06-27

DESIGN.md Format Specification

DESIGN.md Philosophy Document

Get a DigitalOcean account for running this at scale

Introduction #

When you ask an AI coding agent to build a landing page, it produces something functional — but rarely beautiful. The problem isn’t the model’s capability; it’s the lack of a shared design language. Every prompt starts from scratch, every generation drifts from the last, and there’s no persistent memory of what “our design” actually looks like.

DESIGN.md by Google Labs Code solves this. It’s an open-source format specification that gives AI coding agents a persistent, structured understanding of your design system — combining YAML color tokens, typography specs, and spacing rules with natural language prose that describes the intent behind every value. With 20,800+ GitHub stars and 2,319 stars gained in a single day, it’s currently the hottest design tool on GitHub.

What Is DESIGN.md? #

DESIGN.md is a markdown file that serves as the single source of truth for a project’s visual identity. It’s designed to be read by AI coding agents (Claude, ChatGPT, Codex, Cursor, etc.) so they can generate UI that consistently matches your brand — without you having to re-explain your design system every time.

The format has two complementary layers:

┌──────────────────────────────────────────────────┐
│              DESIGN.md Structure                  │
├──────────────────────────────────────────────────┤
│  1. YAML token layer                              │
│     - color: tokens (primary/accent/surface…)    │
│     - typography: font family, sizes, weights     │
│     - spacing: scale (4/8/12/16/24…)             │
│     - radius/shadow: corner & shadow specs        │
│                                                  │
│  2. Prose intent layer                            │
│     - natural-language "why" behind each value    │
│     - brand tone, usage contexts, do's & don'ts   │
│     - context agents can't infer from token values│
└──────────────────────────────────────────────────┘

Why It Works #

Traditional design tokens (like the W3C Design Tokens format) solve “value consistency” but not “intent communication.” An AI agent can read --color-primary: #0A84FF, but it doesn’t know:

  • Should this blue be used on primary buttons or links?
  • Is the brand “serious enterprise” or “playful consumer”?
  • When should this color not be used?

The prose layer of DESIGN.md exists precisely for these answers. It encodes the semantics of your design system into a form AI can understand, so every code generation carries design context.

Quick Start #

# DESIGN.md

## Color Tokens
```yaml
primary:
  value: "#0A84FF"
  usage: "Primary buttons, links, focus states"
accent:
  value: "#FF375F"
  usage: "Badges, promotions, actions needing emphasis"
surface:
  value: "#FFFFFF"
  usage: "Page background, cards"

## Best Practices

1. **Start small**: define 5-10 core tokens before adding every variant
2. **Write the "why"**: each token needs a usage note, not just a hex value
3. **Keep it in the repo root**: agents look for DESIGN.md at the project root by default
4. **Review with agents**: ask your coding agent "does this UI match DESIGN.md?" during code review

## Conclusion

DESIGN.md is becoming the "design system interface standard" for the AI era. When design intent can be communicated structurally to coding agents, the "AI-generated UI is ugly" problem is addressed at the root. If your team relies heavily on AI coding tools, adding a DESIGN.md to your repository is the highest-ROI design investment available today.

💬 Discussion