# When should I continue, resume, or fork a Claude Agent SDK session?

Exam: CCAR-F — Claude Certified Architect - Foundations (CCAR-F)
Knowledge domain: Agentic Architecture & Orchestration
Updated: 2026-11-25T09:22:55.562782+00:00
HTML: https://learningpathx.com/faq/CCAR-F/ccarf-agent-sdk-session-choices.html

## Also asked as

- How do I pick continue, resume, or fork for Claude Agent SDK conversation history?
- What state is preserved when I resume or fork a Claude Agent SDK session?

Continue when you want to append a follow-up to the existing conversational thread. Resume by session ID when a later request or process restart must pick up a particular thread. Fork when you want a new session ID with a copy of the prior conversation so you can explore an alternative while preserving the original history.

* **Continue:** the Python `ClaudeSDKClient` tracks a live session. For a most-recent-session lookup, Python offers `continue_conversation=True` and TypeScript offers `continue: true`. Prefer an explicit session ID when several sessions could qualify.
* **Resume:** keep the ID and the persisted transcript available to the serving host. The SDK normally persists its conversation to disk. If persistence is disabled, the host needs an available transcript to return to it later. A different machine needs access to the transcript through an appropriate storage arrangement.
* **Fork:** use the separate ID for the new conversational path. Two sessions working in the same directory still see real changes to shared files.

The stored conversation can preserve previous tool results as evidence of what was seen at the time. Recheck live state and authorization before relying on that evidence for a write. Manage durable operations, filesystem checkpoints, and database recovery through their own mechanisms.

[Work with Claude Agent SDK sessions](https://code.claude.com/docs/en/agent-sdk/sessions)

Source: [Claude Agent Loops, Sessions, and Runtime Controls](https://learningpathx.com/news/claude-agent-loops-sessions-and-runtime-controls.html)
