← Blog

LangChain vs LangGraph: Which One to Use

LangChain vs LangGraph: Which One to Use

LangChain is a library of model, tool and integration components for building LLM apps. LangGraph is a lower-level runtime for stateful, long-running agents, and LangChain’s own README sends you there when you need more control over orchestration. We build POLYROB, an MIT-licensed agent you install with one command, and its autonomous runs stop at 150 steps and $2.00 by default (docs/[email protected]), so we know which parts of an agent you would otherwise write yourself.

This page compares the two on what their own READMEs say, then shows where a ready-made agent fits when neither library is quite what you need. Facts about LangChain and LangGraph were read from their GitHub READMEs on 2026-11-14.

What is the difference between LangChain and LangGraph?

The short version: LangChain gives you the parts, LangGraph gives you the control flow.

QuestionLangChainLangGraph
How does its README describe it?“The agent engineering platform”, a framework for building agents and LLM-powered applications“Low-level orchestration framework for building stateful agents”
What does it give you?A standard interface for models, embeddings and vector stores, plus integrations with model providers and toolsDurable execution, human-in-the-loop, short-term and long-term memory, deployment support
When does it point you elsewhere?For “more advanced customization or agent orchestration” it points to LangGraphIt says it can be used standalone and also works with any LangChain product
Quickstartuv add langchain, then init_chat_model("openai:gpt-5.5")pip install -U langgraph
License badgeMITMIT

Sources: LangChain README and LangGraph README, both fetched 2026-11-14.

Both projects also point to Deep Agents, a higher-level package for agents that plan, use subagents and work with a file system. Each README describes it as built on its own project, so you will meet that name in both places.

What does LangChain do?

LangChain’s README says it helps you “chain together interoperable components and third-party integrations” so an LLM application is quicker to build. Its quickstart is three lines: import init_chat_model, pick a model by a provider:model string, call invoke.

The pitch in the README rests on six points: data augmentation from many sources, swapping models without rewriting the app, quick prototyping with a component-based design, monitoring and evaluation through LangSmith, a large ecosystem of integrations, and abstraction layers from high-level chains down to low-level components.

Pick LangChain when the job is an application with a model call in the middle: a retrieval pipeline, a summarizer, a tool-using assistant that runs when a user asks and stops when it answers.

What does LangGraph do?

LangGraph’s README lists five reasons to use it, and four of them are about keeping an agent alive and supervised:

Pick LangGraph when you need to own the control flow. If the agent has to pause for approval, resume after a crash, or take different branches depending on state, you want the lower-level runtime, and you will write that graph yourself.

Is LangGraph made by LangChain?

Yes. Both repositories sit in the same GitHub organization, langchain-ai, and each README lists the other as part of one ecosystem next to Deep Agents and LangSmith. LangGraph’s README adds that it can be used standalone.

Do I need to learn LangChain before LangGraph?

No. LangGraph’s README says it “can be used standalone”, so a LangGraph agent does not have to import LangChain. In practice the two are often used together because LangChain supplies the model and tool integrations, but the dependency is a choice, not a requirement.

Is LangGraph still relevant?

On 2026-11-14 the LangChain README still sends readers to LangGraph for agent orchestration, and the LangGraph README describes durable execution and human-in-the-loop as its core features. The project is current in the places where its own maintainers point readers. We did not measure usage and do not compare popularity.

Which should you choose?

Use this as a rule of thumb, built from the two READMEs:

When is neither of them the right answer?

Both are libraries. You write Python that defines the agent, then you decide where it runs, how it is reached, what it remembers between sessions and who is allowed to talk to it. That is the right trade when the agent is a component of your product.

If you want the agent itself, the work is different. POLYROB is an open-source, self-hosted agent that you install, talk to in a terminal, a web console or a chat app, and give goals. You configure it rather than program its control flow. A few of the things the LangGraph README lists as features are built into it:

Installing it is one command, covered on the install page:

curl -fsSL https://polyrob.dev/install.sh | bash

The README at v1.7.9 also shows how to download the script and read it before you run it ([email protected]). The longer story of running one yourself is in our guide to a self-hosted AI agent.

Where does POLYROB fall short of LangChain and LangGraph?

We would rather say it here than have you find it later.

What should you do next?

If you are choosing between the two libraries, write down whether your agent has to pause, resume and branch. If it does, start with LangGraph. If it is a model call with some tools around it, start with LangChain and add LangGraph when the flow gets complicated. Our comparison of nine LangChain alternatives covers CrewAI, LlamaIndex, Haystack, DSPy and Mastra as well. If you are leaving LangGraph itself, read our comparison of LangGraph alternatives.

If what you wanted all along was an agent that already works, read the overview of an open-source AI agent, then run the install command above and give it a first goal. You can add a library later, since POLYROB speaks MCP and exposes an API for your own code to call.

FAQ: LangChain, LangGraph and POLYROB

Can I use LangGraph without LangChain?

Yes. The LangGraph README says it can be used standalone.

Which one is better for production agents?

The LangGraph README lists durable execution, human oversight and deployment support as its focus, so it is the one built around long-running, stateful production workflows. LangChain’s README points to LangGraph for orchestration.

Is POLYROB a replacement for either?

No. They are libraries for writing an agent. POLYROB is an agent you run. You could call a POLYROB agent from code that uses either library, because POLYROB exposes a REST API and an A2A surface (docs/[email protected]).


POLYROB is an open-source AI agent you run and own. Install it or read the docs.