Claude Code
|stacknotice.com
13 min left|
0%
|2,600 words
Claude Code

Claude Code Thinking Modes: --think, --think-hard, ultrathink and ultracode (2026)

The complete breakdown of every Claude Code thinking mode — when each one is worth it, what it actually costs, and the prompts that get the most out of extended thinking.

C
Carlos Oliva
Software Developer
September 14, 202613 min read
Share:
Claude Code Thinking Modes: --think, --think-hard, ultrathink and ultracode (2026)

Claude Code has four distinct levels of thinking intensity, and most developers are using one of two: either the default (no explicit thinking) or ultrathink (maximum). The middle modes — --think and --think-hard — are often the right answer and almost always overlooked.

This guide covers the full spectrum: what each mode does, when to use it, what it costs, and the patterns that get the most out of extended thinking.

The Thinking Mode Spectrum

Before breaking down each mode, the mental model that makes the whole thing click:

Extended thinking in Claude works by allocating a budget of "thinking tokens" — internal reasoning Claude does before producing its response. These tokens aren't shown by default, but they shape the output. More thinking budget means Claude can reason through more steps, consider more edge cases, and catch its own mistakes before committing to an answer.

The modes are a shorthand for different thinking token budgets:

ModeThinking budgetBest for
Default (no flag)NoneSimple tasks, clear instructions
--thinkLow (~2K tokens)Ambiguous tasks, light planning
--think-hardMedium (~10K tokens)Complex logic, multi-step problems
ultrathinkMaximumArchitecture, hard bugs, deep analysis
ultracodeMax code focusImplementation of well-defined specs

Default Mode — When No Thinking Is Right

For most tasks, default mode is correct. If you're asking Claude to rename a variable, add a field to a form, write a simple utility, or implement something you've already fully specified — thinking tokens are wasted overhead.

# These don't need extended thinking — default is fine
claude "rename the userId field to user_id across the codebase"
claude "add an email field to the UserProfile interface"
claude "write a helper to format currency values in EUR"

Default mode is fast and cheap. If the task is unambiguous and the output is easy to verify, use it.

The mistake most developers make: using thinking modes because they feel like Claude will do a better job. For simple tasks, extended thinking produces the same output with extra latency and cost.

--think — Light Extended Thinking

--think allocates a small thinking budget. Claude reasons briefly before responding. The difference from default is most visible on tasks that have a non-obvious best path — where the right answer requires choosing between approaches, not just executing one.

# Good use of --think: task has multiple valid approaches
claude --think "add authentication to the /api/orders endpoint — we're using Better Auth, check how the existing /api/products endpoint handles it"
 
# Good use of --think: need light planning before execution
claude --think "refactor the UserService class to separate the email logic into its own service"

What --think adds over default: Claude will look at the existing code patterns before generating, consider a couple of approaches, and pick the one that fits best. For refactoring tasks this matters — the difference between output that fits your codebase and output that's technically correct but ignores your conventions.

Use --think when:

  • The task requires understanding existing code before generating new code
  • There are multiple valid approaches and you want Claude to choose the best fit
  • You're asking Claude to follow patterns that exist elsewhere in the codebase

Skip --think when:

  • The instruction is completely unambiguous
  • You're generating new code with no existing patterns to match
  • Speed matters more than optimal fit

--think-hard — Medium Extended Thinking

--think-hard is the underused sweet spot. Medium thinking budget — enough for Claude to reason through genuinely complex problems without the latency and cost of ultrathink.

# --think-hard: multi-step logic with edge cases
claude --think-hard "implement the subscription downgrade flow — user stays on pro until currentPeriodEnd, then automatically downgrades to free, send email 3 days before"
 
# --think-hard: debugging with multiple suspects
claude --think-hard "the payment webhook is processing duplicate events despite the idempotency check — trace through the flow and find why"
 
# --think-hard: design question with constraints
claude --think-hard "design the database schema for a multi-tenant SaaS where each tenant has users, projects, and tasks. We're on Postgres with Drizzle, and we need row-level security."

--think-hard is right when:

  • The problem has multiple moving parts that interact
  • Edge cases matter (payment flows, auth logic, data integrity)
  • You're doing design work that will be costly to change later
  • Debugging something non-obvious where the first hypothesis is probably wrong

The difference from --think: --think-hard will actually backtrack and reconsider. With --think, Claude picks an approach and executes. With --think-hard, Claude might reason: "My first approach works, but wait — there's a race condition if two webhooks fire simultaneously. Let me handle that." That self-correction is what the extra thinking budget buys.

ultrathink — Maximum Extended Thinking

ultrathink allocates the maximum thinking budget. Claude reasons exhaustively before producing output. The output quality ceiling is higher, but so is the latency and cost.

# ultrathink in Claude Code
# Type in the prompt or use the keyword directly
"ultrathink: design the complete backend architecture for a B2B SaaS with multi-tenancy, row-level security, and Stripe billing. We're on Next.js 15 with Drizzle and Postgres."
 
# Or when Claude Code picks it up contextually
claude "I need to completely rethink how we handle realtime updates. Currently using polling every 5s, causing performance issues at scale. Consider WebSockets, SSE, and long polling — pick the best fit for our Next.js app and implement it."
# Add "ultrathink" to the prompt to force maximum thinking

ultrathink is worth it when:

  • Architecture decisions that will be expensive to change — data models, API design, system boundaries
  • Hard bugs where you've already tried the obvious explanations and they didn't pan out
  • Security-critical code where being right matters more than being fast
  • Complex algorithms with correctness requirements you can't verify just by reading the code

ultrathink is overkill when:

  • The problem is well-defined and you just need implementation
  • You're in spec-driven development mode and the spec already answered the hard questions
  • You need speed — ultrathink can be 3-5x slower than default

ultracode — Maximum Code Generation

ultracode is the counterpart to ultrathink: maximum focus on code output rather than reasoning. It trades deep reasoning for code generation speed and quantity.

# ultracode: you know what you want, you want it written fast
"ultracode: implement the complete CRUD API for the posts resource — create, read, update, delete, list with pagination. Schema is already defined. Use the same patterns as the users API."

The key distinction from ultrathink: ultracode doesn't reason about whether the approach is correct. It assumes you've already decided that and executes as fast as possible.

ultracode is right when:

  • The spec is fully defined (either you wrote it or ultrathink already reasoned it out)
  • The task is implementation of a known pattern
  • You're generating boilerplate that you'll review and potentially adjust
  • Speed is the constraint, not correctness of approach

The best pattern: ultrathink for design, ultracode for implementation. Use ultrathink to reason through architecture and edge cases, then switch to ultracode to execute the output of that reasoning quickly.

Extended Thinking with Plan Mode

Plan Mode and thinking modes stack. Combining them gets the best of both: Claude reasons through what it's going to do and shows you the plan before executing.

/plan
 
ultrathink: we need to add real-time notifications to the dashboard.
Users should see in-app notifications when their subscription changes,
when a team member is added, and when a project is shared with them.
Current stack: Next.js 15, Drizzle, Postgres, Better Auth.
What's your implementation plan?

Plan Mode + ultrathink produces a reasoned plan you can review and adjust before a single line of code is written. This is the right workflow for anything that touches multiple files or has non-obvious dependencies.

The sequence:

  1. /plan + ultrathink to get a reasoned architecture plan
  2. Review the plan, correct anything that doesn't fit
  3. Execute section by section — switch to ultracode for implementation steps

Cost and Latency Reality

Extended thinking costs more than default mode. The practical numbers (approximate — depends on your plan):

  • --think: ~20-30% more tokens than default, ~1-2s extra latency
  • --think-hard: ~2-3x more tokens, ~5-10s extra latency
  • ultrathink: ~4-8x more tokens, ~15-30s extra latency

For cost optimization, the rule is: match thinking intensity to problem complexity. Using ultrathink on a task that needs --think wastes 4-8x the tokens for no improvement in output.

A mental checklist before choosing a mode:

  • Is the task unambiguous and the output verifiable? → Default
  • Does it require understanding existing patterns? → --think
  • Does it have multiple moving parts or edge cases? → --think-hard
  • Is it architecture, a hard bug, or security-critical? → ultrathink
  • Is the design decided, just need fast implementation? → ultracode

Debugging with Extended Thinking

Extended thinking shines in debugging workflows — specifically the class of bugs where the first hypothesis is usually wrong.

For standard bugs (N+1 queries, obvious null pointer, missing await), default mode is fine. Claude recognizes the pattern immediately.

For novel bugs, --think-hard or ultrathink changes the quality of output significantly:

# Standard bug — default is fine
claude "fix the TypeError: Cannot read property 'map' of undefined in ProductList.tsx line 42"
 
# Novel bug — use --think-hard or ultrathink
claude --think-hard "the dashboard is showing stale data for about 30 seconds after a user updates their profile. The mutation invalidates the cache correctly via React Query, but the stale data persists. This only happens in production, not locally. We're on Vercel with Edge Runtime."

With --think-hard, Claude will reason through: is it the cache invalidation? The Edge Runtime caching layer? A CDN issue? A race condition between the mutation and the next fetch? It considers multiple suspects before committing to an explanation.

Without thinking, Claude picks the most statistically likely explanation (usually cache) and goes with it. That's often right. For production-only bugs, it's often wrong.

Reading Thinking Output

When Claude Code is in extended thinking mode, you can sometimes see the reasoning process — it appears as internal monologue before the response. This is worth reading when:

  • You want to understand why Claude made a particular design choice
  • You're not sure the output is correct and want to check the reasoning
  • You're learning how Claude approaches a class of problem

If Claude's thinking shows it considering an approach you know is wrong, you can interrupt and redirect before it commits to the output. This is one of the underused advantages of visible thinking.

The Mode Matching Rule

The practical summary: thinking modes are a dial, not an on/off switch. The right setting matches the complexity of the problem.

Most developers would get better results — and spend less — by using --think-hard more and ultrathink less. ultrathink is genuinely needed for architecture and hard bugs. For the 80% of complex-but-not-exceptional tasks, --think-hard produces the same quality at a fraction of the cost and latency.

Default and --think handle the other 90% of daily development work. The goal isn't always maximum thinking — it's matching the reasoning budget to what the problem actually requires.

That calibration is the skill. Once you've internalized which mode fits which problem class, you stop fighting Claude Code for output quality and start directing it toward what you need.

#claude-code#ultrathink#productivity#ai#workflow
Share:
C
Carlos Oliva
Software Developer · stacknotice.com

Software developer with hands-on experience building production apps with React, Next.js, Angular, TypeScript, and Spring Boot. I write practical guides on Claude Code, AI tools, and modern web development — covering the decisions and trade-offs that senior-level tutorials actually explain.

More about Carlos

Enjoyed this article?

Get weekly insights on Claude Code, React, and AI tools — practical guides for developers who build real things.

No spam. Unsubscribe anytime. By subscribing you agree to our Privacy Policy.