One question decides it. Here is the real difference inside Claude Code, the exact file for each, and when to reach for which.
The One Question
People overcomplicate this. There's really just one question that tells you which to build: can you write the exact steps out ahead of time, or does the next move depend on what Claude finds along the way?
If you can write the steps out and they'd run the same way every time, you want a workflow. If the steps change based on what it discovers, you want an agent. That's the whole decision. Everything below just makes it obvious.
Workflow = Recipe
You wrote the steps down. Anyone can run it and get the same result every time. No guessing, no improvising, it just follows the path.
Agent = Chef
You hand over a goal, like "make something great with what's in the fridge," and it decides the steps for itself based on what it actually finds.
Here's the trap almost everyone falls into: they reach for the chef when a recipe would have been cheaper, faster, and more reliable. When you already know the steps, you don't need something to think. You need something to execute.
A workflow is a path you decide once and lock in. Same steps, same order, every run. You're not asking Claude to think, you're asking it to follow the steps you already mapped. In Claude Code that's a slash command: a file at .claude/commands/<name>.md that lists the steps, so typing /<name> runs the whole thing.
The tell: you can write down every step before you ever start, and nothing about the task changes based on what Claude finds.
Great Workflow Jobs
Notice the pattern: in every one of these, you already know the steps. There's nothing to figure out, just a sequence to run. That's a workflow.
Why It Wins
Predictable, cheap, and fast. You're paying Claude to run a path you already mapped, not to reason at every step. For anything repetitive, that's exactly what you want.
An agent is a specialist you hand a goal, and it figures out its own steps to get there. You don't script the path. You give it the outcome and let it decide what to do next based on what it actually finds. In Claude Code that's a subagent: a file at .claude/agents/<name>.md that runs in its own clean context, so it isn't dragging your whole chat history around.
The tell: you can't write step three until you see what step two turns up. The task needs judgment, not just execution.
Great Agent Jobs
In every one of these, you can't hand it a script, because you don't know what it'll run into. You hand it a goal and trust it to think. That's an agent. The simplest way to use one is to just say "use a subagent to..." on a task and let Claude Code take it from there.
The Tradeoff
More powerful, less predictable, and more expensive, because it's reasoning at every turn. Worth it when the task truly needs to think. A waste when a workflow would have done the job.
Build a Workflow When
Build an Agent When
The clean line: a workflow is a path you control, an agent is the model directing its own process. When in doubt, start with a workflow. Only reach for an agent when the task genuinely needs to think for itself, and you'll stop paying for autonomy you never needed.
The Only AI Masterclass You Need
If this guide helped, but you’re looking to go deeper, I got you!! My 30-Day Challenge takes you from saving AI tips you never use to actually building with AI, step-by-step.
I show you exactly how I automated two e-commerce brands, my social media, and most of my personal life, then hand you the agents, workflows & systems to do the same. I’m teaching you every single thing I know with one lesson and one build a day.
Join the AI Masterclass →© 2026 Mariah Brunner. All rights reserved.