Why a workflow beats a single giant prompt
The most common beginner mistake is to type one big request ("build me a billing system") and hope. Claude will try, but it has to guess at your conventions, your edge cases and what "done" means. The fix is a simple rhythm that experienced Claude Code users follow almost by instinct:
- Explore: understand the relevant code before deciding anything.
- Plan: agree on an approach while changing nothing.
- Code: implement in small steps, verifying as you go.
- Commit: write a clean commit or pull request with a real description.
Phase 1: Explore
Point Claude at the area you care about and ask it to read, not write:
read the files that handle invoices and summarize how an invoice moves from draft to paid.
don't change anything yet.Reading costs context, so for wide-ranging investigations Claude will often hand the search to a built-in Explore subagent, which reads many files in its own context and returns just the findings.
Phase 2: Plan
Switch to plan mode with Shift+Tab (the status bar shows plan mode on), or start your prompt with /plan. In plan mode Claude researches and proposes, but it can't edit your files.
This is where you catch misunderstandings cheaply. Push back: "Don't touch the PDF yet." "Fees should compound monthly." Press Ctrl+G to open the plan in your editor and edit it directly.
For bigger features, ask Claude to interview you about requirements and write the answers to a SPEC.md. Then start a fresh session that builds from the spec. The clean context and written spec make a dramatic difference.
Phase 3: Code, with a check
Approve the plan and let Claude implement. The single most important thing you can do here is give it a check to run: a test command, a build, a linter, a screenshot to compare.
implement step 1 and 2. after each step run `npm test -- invoices` and fix failures before moving on.When Claude can see real test output, it fixes its own mistakes instead of announcing success.
Phase 4: Commit
Claude is excellent at git. It reads the diff and writes descriptive messages:
commit this with a descriptive message
create a prWith the GitHub CLI (gh) installed and signed in, "create a pr" pushes a branch and opens a pull request with a summary of what changed and why. Later, claude --from-pr 1234 resumes the session linked to that PR.
- ⋮⋮Ask Claude to read the relevant code and summarize it
- ⋮⋮Switch to plan mode and agree on an approach
- ⋮⋮Implement step by step, running tests after each
- ⋮⋮Have Claude commit and open a pull request
Check your understanding
What can't Claude do while in plan mode?
What's the most effective addition to a 'code' phase prompt?
How can you enter plan mode?
Why write a SPEC.md and start a fresh session to build from it?