---
title: DESIGN.md for mobile apps: a complete example for iOS and Android
description: A complete DESIGN.md for an iOS and Android app: tokens, light and dark colors, the platform rules the spec leaves out, and a free file to download.
author: Bob Poláček
topic: AI
published: 2026-12-01
updated: 2026-12-01
verified: 2026-12-01
source: https://www.appetiteui.com/blog/design-md-mobile-app
---

# DESIGN.md for mobile apps: a complete example for iOS and Android

A complete DESIGN.md for an iOS and Android app: tokens, light and dark colors, the platform rules the spec leaves out, and a free file to download.

By Bob Poláček, updated December 1, 2026, last verified December 1, 2026.

A DESIGN.md for a mobile app holds two layers the format already has and one it leaves to you. The YAML tokens carry colors for light and dark, type, spacing, radii and motion. The prose says what each value is for. The iOS and Android rules have no field in the spec, so a phone app writes them into the prose: what adapts per platform and what stays the brand.

The Appetite UI DESIGN.md is built that way, from the same token source as the Figma file and [Appetite UI Code](https://www.appetiteui.com/code), and you can [download it free](https://www.appetiteui.com/design.md). Below I go through it section by section, with the parts a phone app adds, and show how Claude Code, Cursor and Stitch pick it up.

**Key takeaways**

- DESIGN.md is one Markdown file: YAML tokens an agent applies as they are, and prose that says what each token is for.
- The draft spec from Google Labs has no iOS or Android section and no `dp` unit. A mobile file writes sizes in px and puts the platform rules in prose.
- Keep the brand identical on both platforms and list what adapts: touch targets, press feedback, Back and sheet gestures, safe areas, text size, Reduce Motion.
- Generate the tokens from the source your app's theme already uses, and run `npx @google/design.md lint` after every change.
- Claude Code does not load DESIGN.md on its own. Import it in CLAUDE.md with `@DESIGN.md`, or point to it from AGENTS.md.

## What is DESIGN.md?

DESIGN.md is a plain-text file that describes a design system to coding agents: design tokens in YAML, and Markdown prose on how to apply them. Google Labs open-sourced the draft specification on April 21, 2026. The format comes from Stitch, Google's AI design tool, which exports and imports it, and the spec is at version alpha under the Apache-2.0 license.

The two layers have different jobs. The tokens are the values the agent must use, exactly. The prose is the context: which blue is for the main action, which gray is for captions, when a card gets a shadow. An agent that reads only a token file knows the values and guesses their jobs. An agent that reads only prose guesses the values.

The tokens sit in the front matter between two `---` lines, or in fenced `yaml` blocks inside the sections. The spec merges them into one tree and rejects a file that defines a top-level key twice. It defines six token groups: `colors`, `typography`, `rounded`, `spacing`, `motion` and `components`. A `primary` color is required; everything else is optional.

The prose follows a fixed order of ten sections, from Overview to Do's and Don'ts. A section that does not apply can go on the `omitted` list, with a reason, so readers and tools see it was left out on purpose. The short definition is on the [DESIGN.md glossary page](https://www.appetiteui.com/glossary/design-md).

## What does the spec leave out for a phone app?

Platforms. The spec never mentions iOS or Android. Mobile shows up only as a screen width: the smallest of its breakpoints, `sm`, next to `md` for tablet, `lg` for laptop and `xl` for desktop. That is a website's model of a phone: a narrow viewport. A native app has no breakpoint to fall back on. It has a platform, the user's settings and the device's safe areas.

The public examples lean the same way. VoltAgent's awesome-design-md collection gathers DESIGN.md files extracted from public websites, so their defaults are a web page's defaults.

Units tell the same story. The spec accepts px, em and rem. There is no pt and no dp, the units iOS and Android measure in. Write sizes in px and say once, in the Overview, that one px means one point on iOS and one dp on Android. Both are density-independent units, so the numbers carry over as they are.

Two more gaps matter on a phone. There is no token group for shadows, so elevation lives in prose. And dark mode is the one mobile concern the spec does cover: colors can carry `light` and `dark` maps, while roles that do not change stay at the top level.

**What a phone app adds to a DESIGN.md, and the section it belongs in. Values from Apple's and Google's guidelines, as Appetite UI uses them**

| What the agent needs to know | iOS | Android | Section |
| --- | --- | --- | --- |
| Smallest touch target | 44 × 44 pt | 48 × 48 dp | Layout |
| Press feedback | The control's Pressed color | A ripple under the finger | Motion & Micro-interaction |
| Going back | A swipe from the left edge, or the back button | System Back, including predictive back | iOS and Android |
| Closing a sheet | Swipe down | Swipe down, or Back | Components |
| Safe areas | Status bar, sensor housing, home indicator | Status bar and gesture bar, edge to edge | Layout |
| Text size | Follows the system text size | Follows the system font size | Typography |
| Motion | Respects Reduce Motion | Respects Remove animations | Motion & Micro-interaction |
| Light and dark | Follows the system appearance | Follows the system theme | Colors |

The last column uses one section the spec does not define. That is allowed: the spec tells tools to keep a heading they do not recognize, not to reject the file. The Appetite UI file adds one, iOS and Android, as the single place where the two platforms differ.

## Which differences should the file allow?

Decide this once and write it down, or the agent decides per screen. A model that knows both platforms reaches for each one's defaults: a Material switch on Android, a different corner radius, a font per operating system. The result looks like two apps that share a logo.

The rule Appetite UI follows is brand first, convention where it matters to users. A platform difference is allowed for three reasons only:

1. **The OS contract.** What the user's hands expect and the system provides: Back on Android, a swipe down to close a sheet, keyboard return keys, a tap on the status bar to scroll to the top, safe areas, haptics.
2. **The user's settings.** Reduce Motion, text size, light and dark.
3. **Native touch feedback.** Android users expect a ripple under the finger, iOS users expect the control to change to its Pressed color.

Everything else stays identical on both platforms: colors, radii, type, layout, icons, motion curves and component shapes.

In Appetite UI Code the same rule is one switch in the theme between iOS and Material conventions, and the code never branches on the operating system for a design decision. The [AGENTS.md article](https://www.appetiteui.com/blog/agents-md-mobile-app) shows that rule. A DESIGN.md has no theme to switch, so it states the rule in words, and the agent applies it in whatever stack it writes.

## What is in the Appetite UI DESIGN.md?

Every value in the front matter comes from the token source behind the Figma file and Appetite UI Code, written out by a script, so the file and the kit cannot disagree. The names are the Figma variable names, the ones the docs and the agent kit use too. Here are the colors, with the light and dark maps:

**DESIGN.md** Appetite UI DESIGN.md, front matter, excerpt

```yaml
colors:
  primary: "#155DFC"
  light:
    brand:
      lighter: "#EFF6FF"
      light: "#DBEAFE"
      base: "#155DFC"
  ...
  dark:
    brand:
      lighter: "#132150"
      light: "#0D2673"
      base: "#2B7FFF"
```

Then the prose, one section after another:

**What each section of the Appetite UI DESIGN.md says**

| Section | What it says |
| --- | --- |
| Overview | One visual language on iOS and Android, the three reasons a platform may differ, sizes in px read as pt on iOS and dp on Android, light and dark following the system |
| Colors | Each role by its job: text, icons, surfaces, borders, brand and states; which text roles pass 4.5:1 on their surfaces and which are for large text or disabled controls only |
| Typography | Inter in the kit's text styles, and text that follows the system text size, with a cap on labels inside fixed-height controls |
| Layout | The spacing scale, touch targets of 44 pt and 48 dp, content kept inside the safe areas, edge to edge on Android |
| Elevation & Depth | Shadows by level, written in prose, and floating surfaces that lift to a lighter gray in dark mode, where a shadow barely shows |
| Shapes | The radius scale |
| Motion & Micro-interaction | Durations and easing curves, Reduce Motion respected by every moving surface, Pressed colors on iOS and a ripple on Android, haptics on selection controls |
| Voice & Content Strategy | On the `omitted` list: the voice belongs to your app, not to a UI kit |
| Components | Tokens for the core controls by reference to the color, type and shape tokens, and how sheets, tabs and Back behave |
| Do's and Don'ts | The mistakes agents make most often: typed hex values, icon colors used for text, the error fill used as error text, a design that branches on the operating system |
| iOS and Android | The one added section: every item that adapts per platform, with the value on each |

The Layout section is where the platforms first differ:

**DESIGN.md** Appetite UI DESIGN.md, Layout, excerpt

```markdown
Every size here is px, read as pt on iOS and dp on Android. Anything a finger can press keeps a
touch target of at least 44px on iOS (`spacing.touch-target-ios`) and 48px on Android
(`spacing.touch-target-android`), even when the control draws smaller: a 32px chip still answers a
touch across the full target. Content stays inside the safe areas: on iOS below the status bar and
the sensor housing and above the home indicator, on Android inside the status bar and the gesture
bar, with the app drawn edge to edge behind both.
```

Components carry tokens by reference, so a change to a color reaches every control that uses it:

**DESIGN.md** Appetite UI DESIGN.md, front matter, excerpt

```yaml
components:
  button-primary:
    backgroundColor: "{colors.primary}"
    textColor: "{colors.light.static.static-white-0}"
    typography: "{typography.base-emphasized}"
    rounded: "{rounded.full}"
    height: "{spacing.11}"
```

And the added section closes the file:

**DESIGN.md** Appetite UI DESIGN.md, iOS and Android, excerpt

```markdown
## iOS and Android

This section is the one place where the two platforms differ. Everything not listed here is
identical on iOS and Android. Values are in px, read as pt on iOS and dp on Android, from the kit's
Platform variables:

| What | iOS | Android | Token |
| --- | --- | --- | --- |
| Smallest touch target | 44px | 48px | `platform/min-touch-target` |
| Single-line list row, at least | 44px | 56px | `platform/list-row/min-height` |
```

The whole file is on [appetiteui.com/design.md](https://www.appetiteui.com/design.md) and in the free [Appetite UI base on GitHub](https://github.com/bpolacekcz/appetite-ui-base), and `npx @google/design.md lint` reports no errors on it.

Free, under the MIT License. Put it at the root of your project, next to AGENTS.md.

## Should a platform difference be a token or a sentence?

A value a machine applies is a token. A choice between patterns is a sentence.

The touch target is a value, and it differs per platform, so it needs two tokens. The spec has no platform key, so give them platform names in one group, a pair of spacing tokens ending in `-ios` and `-android`, and add one sentence in Layout that says which to use. An agent writing a React Native screen for both platforms then reads the right one from your theme, and an agent writing SwiftUI takes the iOS value.

Going back is a choice of pattern. No token can say that Back on Android returns to the previous screen and a swipe from the left edge does it on iOS. That is one line of prose in the iOS and Android section.

For the cases in between, look at your code. If your theme file has a value for it, make it a token. If your code reads the platform to decide it, write a sentence.

## How do Claude Code, Cursor and Stitch use the file?

Put DESIGN.md at the root of the project, next to AGENTS.md. Then make sure each tool reads it: Claude Code, Codex and Cursor load their own instruction files automatically, CLAUDE.md, AGENTS.md and Cursor's rules, and DESIGN.md is not one of them.

- **Claude Code** reads CLAUDE.md at the start of every session and pulls in the files it imports with `@`. Add one line.
- **Codex, Cursor and other agents that read AGENTS.md** need one sentence in it that sends them to the file.
- **Stitch** imports a DESIGN.md to give a project your design system, and exports one from a project you designed there.

**CLAUDE.md**

```markdown
@AGENTS.md
@DESIGN.md
```

**AGENTS.md** One line near the top

```markdown
Before you build or change UI, read DESIGN.md and use its tokens. Never type a value it already defines.
```

Check the file whenever it changes. `npx @google/design.md lint DESIGN.md` fails on token references that do not resolve, and warns about a missing primary color, component text below 4.5:1 contrast, sections out of order and color tokens no component uses. `diff` compares two versions token by token, and `export` writes the tokens as a Tailwind theme, CSS custom properties or W3C DTCG JSON.

The spec is alpha and the CLI changes with it, so pin the package version in your project's scripts. A new linter release should not fail your build overnight.

## How do DESIGN.md, AGENTS.md and a token file split the work?

Each answers a different question, and a mobile project is better with three short files than with one long one.

**Three files an agent reads in a mobile project**

| File | Answers | Read by | Example line |
| --- | --- | --- | --- |
| DESIGN.md | What the design is: the values and what each is for | Agents you point to it, Stitch, the design.md CLI | Error text uses the error text color, never the error fill |
| AGENTS.md | How to work in this repository: components, commands, checks | Codex, Cursor, Claude Code when there is no CLAUDE.md | Run the type check and the literal check before you finish |
| tokens.json, W3C DTCG | The values, for tools | Build scripts, Figma variables, theme generators | `brand.base` is #155DFC in light and #2B7FFF in dark |

Keep one source of values. Generate the DESIGN.md tokens from the same source as the theme your app runs on, and never type a hex value into it by hand: the first time someone changes the brand color in one place, the agent keeps building in the old one. Appetite UI keeps one W3C DTCG source for the Figma variables, the four code stacks and the DESIGN.md. The [token output per stack](https://www.appetiteui.com/blog/figma-token-to-swiftui-compose-flutter-css) shows what that source becomes in SwiftUI, Compose, Flutter and CSS.

## What does a DESIGN.md not do?

It does not give the agent components. With the file, the agent knows your colors, type and spacing and still draws every control itself: its states, its touch target, its accessibility label, its behavior on each platform. Two screens built a week apart get two versions of the same switch. A DESIGN.md narrows the guesses. A component library removes them.

It does not enforce anything. The linter checks the file, not your app. To catch a hex value an agent typed into a screen anyway, run a check on the code, like the literal check in the [AGENTS.md article](https://www.appetiteui.com/blog/agents-md-mobile-app).

It is a draft. The spec is alpha, and its own text says the Components section is actively evolving. Expect renamed keys and new rules, and read the release notes before you update the CLI.

Every Appetite UI component in React Native, SwiftUI, Flutter and Jetpack Compose, with the App Starter and an agent kit that already uses the tokens this DESIGN.md describes. Every release after you buy is included.

Start with the free file: [download the Appetite UI DESIGN.md](https://www.appetiteui.com/design.md), or take the [Appetite UI base on GitHub](https://github.com/bpolacekcz/appetite-ui-base), an MIT Expo app that carries it. [How to vibe code a mobile app](https://www.appetiteui.com/blog/how-to-vibe-code-a-mobile-app) puts the file into the whole setup, and the [Claude Code](https://www.appetiteui.com/works-with/claude-code) and [Cursor](https://www.appetiteui.com/works-with/cursor) pages show the setup per tool.

**In short**

- A mobile DESIGN.md is the spec's tokens and sections plus the platform rules the spec leaves out.
- Sizes go in px, read as pt on iOS and dp on Android. Dark mode goes in the `light` and `dark` color maps.
- Values that differ per platform are paired tokens. Choices between patterns are sentences.
- Point every agent to the file: `@DESIGN.md` in CLAUDE.md, one line in AGENTS.md.
- Lint the file on every change, and check the app's code separately.

## Questions

### What is DESIGN.md?

A Markdown file that describes a design system to coding agents: design tokens in YAML and prose on how to apply them, in a fixed order of sections. Google Labs open-sourced the draft spec on April 21, 2026, and it is at version alpha.

### Does Claude Code read DESIGN.md automatically?

No. Claude Code loads CLAUDE.md, and AGENTS.md when the project has no CLAUDE.md. Add the line @DESIGN.md to CLAUDE.md, or tell the agent in AGENTS.md to read DESIGN.md before it builds UI.

### Can DESIGN.md describe dark mode?

Yes. Mode-dependent colors go in light and dark maps inside colors, and roles that do not change stay at the top level of colors.

### Does DESIGN.md work for React Native, SwiftUI and Jetpack Compose?

Yes. The file does not depend on a framework, and the agent applies the values in whatever it writes. The CLI exports only to Tailwind, CSS custom properties and W3C DTCG, so generate your native theme file and the DESIGN.md from one source rather than one from the other.

### Where do iOS and Android differences go in a DESIGN.md?

Into the prose, because the spec has no platform field. Write a value that differs as a pair of tokens with platform names, and a choice between patterns as a sentence, ideally in one section of its own.

### How do I check a DESIGN.md?

Run npx @google/design.md lint DESIGN.md. It fails on broken token references and warns about a missing primary color, component text below 4.5:1 contrast, sections out of order and unused color tokens. diff compares two versions token by token.

### Is the Appetite UI DESIGN.md free?

Yes. Download it at appetiteui.com/design.md or take it from the free Appetite UI base on GitHub. It describes the tokens and the rules; the components are in Appetite UI Code.

## Sources

1. [Google: Stitch's DESIGN.md format is now open-source](https://blog.google/innovation-and-ai/models-and-research/google-labs/stitch-design-md/), April 21, 2026, read December 1, 2026
2. [Google Labs: DESIGN.md format specification](https://github.com/google-labs-code/design.md/blob/main/docs/spec.md), version alpha, read December 1, 2026
3. [Google Labs: design.md repository and CLI](https://github.com/google-labs-code/design.md), CLI 0.4.0, read December 1, 2026
4. [Claude Code documentation: How Claude remembers your project](https://code.claude.com/docs/en/memory), read December 1, 2026
5. [AGENTS.md](https://agents.md/), read December 1, 2026
6. [VoltAgent: awesome-design-md](https://github.com/VoltAgent/awesome-design-md), read December 1, 2026
7. [Apple Human Interface Guidelines: Accessibility](https://developer.apple.com/design/human-interface-guidelines/accessibility), read December 1, 2026
8. [Android Developers: Make apps more accessible](https://developer.android.com/guide/topics/ui/accessibility/apps), read December 1, 2026
9. [Appetite UI DESIGN.md](https://www.appetiteui.com/design.md) and the platform conventions of Appetite UI Code, read December 1, 2026
