Claude Agent SDK vs LangGraph: a ready harness or a runtime to build on
The Claude Agent SDK packages Claude Code's agent loop, built-in tools, subagents and context management as a Python and TypeScript library for Claude models under Anthropic's Commercial Terms, while LangGraph is an MIT-licensed, model-neutral runtime for agents defined as explicit graphs, so the SDK fits file-centric, long-horizon agents on Claude and LangGraph fits workflows that need explicit control flow or several model vendors.
Checked
These two sit at different levels. The Claude Agent SDK is a finished harness: the same tools, agent loop and context management that power Claude Code, embedded in a team's own process. LangGraph is a runtime for building a harness: the team defines nodes, state and edges, and chooses the models and tools.
Anthropic's own guidance is to start with model APIs directly and add a framework only when it earns its place. The SDK is Anthropic's answer for teams that want a production loop without writing one. LangGraph is the answer for teams that want the loop's shape under their control.
What each provides
Claude Agent SDK
Built-in tools to read, write and edit files, run commands and search the web, plus hooks at key points in the loop, subagents, MCP, permissions, sessions that can be resumed or forked, skills, commands, memory and plugins. It runs the Claude Code binary under the hood.
LangGraph
Durable execution and persistence, human-in-the-loop editing of state, short-term and long-term memory, streaming, and debugging through LangSmith. Tools and models are whatever the team wires in.
Licence, models and hosting
Use of the Claude Agent SDK is governed by Anthropic's Commercial Terms of Service, which is not an OSI open-source licence. It is built for Claude models. Anthropic also offers Claude Managed Agents, in public beta since 8 April 2026, which hosts the harness for token rates plus $0.08 per session-hour.
LangGraph is MIT licensed, runs with any model a team connects, and is self-hosted or deployed on LangChain's or Google's managed runtimes.
Which fits which job
Claude Agent SDK fits
Agents that work over files and shells, such as coding, research and operations agents, where Claude models pass the eval and the team wants Claude Code's tested context management.
LangGraph fits
Workflows with explicit branches and approval steps, agents that route steps to models from several vendors, and teams that need an open-source licence.
Together
A LangGraph node can call an agent built on the SDK for a file-heavy subtask while the graph keeps control of the overall flow.
How Motiontic approaches it
Motiontic's engineers are framework-neutral. They choose per project after a short spike on the client's real task, keep prompts, tool definitions and evals outside the framework so a later switch is a refactor rather than a rewrite, and hand the eval suite to the client's team so the next framework decision can be measured.
Claude Agent SDK and LangGraph, figures retrieved 30 October 2026
| Claude Agent SDK | LangGraph | |
|---|---|---|
| What it is | Claude Code's agent loop as a library | Low-level runtime for graph-shaped agents |
| Licence | Anthropic Commercial Terms of Service | MIT |
| Models | Claude | Any model the team connects |
| Languages | Python, TypeScript | Python, JavaScript / TypeScript |
| Latest version | 0.2.175 Python, 0.3.314 TypeScript (30 Oct 2026), still 0.x | 1.2.18 (26 Oct 2026); 1.0 on 17 Oct 2025 |
| Built in | File, shell and web tools, subagents, hooks, MCP, permissions | Graph, state, checkpoints, human-in-the-loop |
| State | Sessions that resume or fork | Durable execution and persistence |
| Hosted option | Claude Managed Agents (beta), plus $0.08 per session-hour | LangChain and Google managed runtimes |
| Downloads, last week | PyPI 8.08M; npm 17.10M | PyPI 13.76M; npm 4.96M |
Common questions
Is the Claude Agent SDK open source?
Its use is governed by Anthropic's Commercial Terms of Service, not an OSI open-source licence, except where a component's own LICENSE file says otherwise. LangGraph is MIT licensed.
What was the Claude Agent SDK called before?
It was the Claude Code SDK. Anthropic renamed it on 29 September 2025 because the harness had begun to power most of its major agent loops.
Can the Claude Agent SDK use non-Claude models?
Anthropic describes the SDK as Claude Code as a library, built for Claude models. Teams that need to route steps across several vendors usually put that routing in a model-neutral runtime such as LangGraph.
Does the Claude Agent SDK support subagents and MCP?
Yes. Subagents, MCP, hooks, permissions, sessions, skills and plugins are all listed capabilities in Anthropic's SDK overview.
Related
AI agent development
Agents that do real work for users, with the evals, traces and guardrails to keep them in production.
LangChain vs LangGraph
The agent layer and the runtime underneath it, compared after the 1.0 releases.
Pydantic AI vs LangGraph
A typed, code-first agent framework compared with a graph runtime.
Agent harness
The loop, tools, context, permissions and state that sit around the model.
Subagent
A helper agent with a clean context that hands back a short answer.
Sources
- Claude Agent SDK overview (capabilities, licence)
- Claude blog, Building agents with the Claude Agent SDK (2025-09-29)
- Claude blog, Claude Managed Agents (2026-04-08)
- GitHub, anthropics/claude-agent-sdk-python
- Anthropic, Building effective agents (2024-12-19)
- LangGraph docs, overview
- GitHub, langchain-ai/langgraph (stars, licence, releases)
Running agents that have to hold up?
Describe the agent, the systems it touches and what it must never get wrong. The first call is with a lab engineer, who will say plainly whether it is ready for production, and whether Motiontic is the right team.