From Zero to Deploy · Module 3 · Lesson 3.1

3.1 Your first SPEC.md

Learn to write a spec, the short list that makes the AI build what you want (not what it imagines).

⏱ 15 min

The problem: vague requests

Ask an AI to “make a shopping list app” and it has to guess a lot. Is there a login? Where is data saved? Should it use React? Does it work on a phone?

It guesses, and it often overdoes it: you get a huge project full of things you didn’t ask for and don’t understand.

A spec fixes that. It’s a short file called SPEC.md where you decide up front what you want and what you don’t. The AI follows the spec, and you can check whether it did.

Vague request With a spec
The AI decides how big the project is You decide how big the project is
Features show up that you didn’t ask for The “out of scope” section prevents that
Hard to tell when it’s done You have a “done when” list to check
Everything at once One step at a time, testing along the way

The parts of a good spec

Section What it’s for
Goal What the app does, in one or two sentences
Who it is for Who uses it and where (phone, computer)
Core features The minimum for the app to be useful, one per line
Extras What can wait until the core works
Out of scope What the AI should not do
Technology What to build with. Simple is better at first.
Done when How you’ll know it works
How to work Rules for the AI: one step at a time, explain what changed

A good feature is specific and testable. Compare:

  • Bad: “make the app look nice”
  • Good: “buttons are at least 44px tall so they’re easy to tap on a phone”

Build yours

Fill in the fields and watch the SPEC.md take shape next to them. No idea yet? Click Show a finished example. What you type is saved in this browser.

Build your spec

SPEC.md generator

SPEC.md
# SPEC: (project name)

## Goal
(fill in)

## Who it is for
(fill in)

## Core features
- (fill in)

## Extras (only after the core features work)
- (fill in)

## Out of scope (do not build)
- (fill in)

## Technology
Plain HTML, CSS, and JavaScript (no framework)

## Done when
- (fill in)

## How to work
- Build one core feature at a time.
- After each step, stop and explain what changed before moving on.
- Keep the code simple and commented; I'm learning.

Using the spec with Claude Code

  1. Click Download and move SPEC.md into your project folder (it can be a new folder, like my-first-app).
  2. Open Claude Code in that folder (claude) and ask for a plan before any code:
Read SPEC.md. Before writing any code, tell me in a few lines how you plan to build it and which files you'll create.
  1. If the plan makes sense, ask for just the first step:
Great. Build only the first core feature, then stop so I can test it.
  1. Test it in the browser. Did it work? Ask for the next one. Didn’t work? Describe what happened (“I clicked add and nothing showed up”) and ask it to fix it.
Task

Now on your machine

0 of 5 done

Checkpoint

Check what you learned

  1. Which of these features is well written?

  2. What is the "Out of scope" section for?

  3. Claude finished the first feature. Now what?

Finished the lesson?

Mark it complete to track your progress.