Stackmark › Prompts

Fork a Claude Code session to try a different approach

`/fork` branches from the current point so you can experiment without losing context — both threads run independently.

  • Type: Prompt
  • Tags: Coding Agent Hacks, Intermediate, Claude Code
  • Updated: 2026-10-01

Prompt

`/fork` branches from the current point so you can experiment without losing context — both threads run independently. Mid-session you want to try a different approach but don't want to lose your context or pollute the thread with failed attempts. `/fork` branches from the exact point. The same flag works from the CLI when resuming. If the new direction doesn't pan out, close the fork and the original is untouched. Implementation example: # In an active session: /fork # Or from CLI: claude --continue --fork-session

More prompts

Privacy · Terms · llms.txt