# Serving an agent with the LangGraph CLI dev command

**URL:** <https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622>\
**Category:** LangGraph\
**Tags:** self-hosted, python-help\
**Created:** [April 28, 2026, 10:29pm UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622 "2026-04-28T22:29:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![wigging](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.langchain.com/wigging/32/2830_2.png) [@wigging](https://forum.langchain.com/u/wigging)\
**Post date:** [April 28, 2026, 10:29pm UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622/1 "2026-04-28T22:29:28Z")

</div>

I’m using the LangGraph CLI version 0.4.24 to serve an agent with the `langgraph dev` command. According to the command line help menu (printed below), the `dev` option is for development. Why is `dev` just for development purposes? Why should I not use it to serve an agent on a remote server for other people to access via the API?

It looks like Docker is the only other solution for serving the agent. But the `dev` command doesn’t require Docker so obviously it’s possible to serve an agent without Docker. If I already have Redis and Postgres running on the server where I want to serve the agent, then I see no reason to use Docker for this.

```plaintext
$ uv run langgraph --help

Usage: langgraph [OPTIONS] COMMAND [ARGS]...

Options:
  --version Show the version and exit.
  --help Show this message and exit.

Commands:
  build 📦 Build LangGraph API server Docker image.
  deploy [Beta] Build and deploy a LangGraph image to...
  deploy delete [Beta] Delete a LangSmith Deployment.
  deploy list [Beta] List LangSmith Deployments.
  deploy logs [Beta] Fetch LangSmith Deployment logs.
  deploy revisions [Beta] Manage deployment revisions.
  deploy revisions list [Beta] List revisions for a LangSmith Deployment.
  dev 🏃‍♀‍➡ Run LangGraph API server in development...
  dockerfile 🐳 Generate a Dockerfile for the LangGraph API...
  new 🌱 Create a new LangGraph project from a template.
  up 🚀 Launch LangGraph API server.
  validate ✅ Validate the LangGraph configuration file.

```

---

<div class="post-metadata">

**Author:** ![wfh](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.langchain.com/wfh/32/33_2.png) [@wfh](https://forum.langchain.com/u/wfh)\
**Post date:** [April 28, 2026, 10:41pm UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622/2 "2026-04-28T22:41:32Z")

</div>

It has no horizontal scalability or persistence.

---

<div class="post-metadata">

**Author:** ![wigging](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.langchain.com/wigging/32/2830_2.png) [@wigging](https://forum.langchain.com/u/wigging)\
**Post date:** [April 28, 2026, 10:45pm UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622/3 "2026-04-28T22:45:18Z")

</div>

I thought the dev server uses in-memory persistence?

---

<div class="post-metadata">

**Author:** ![wfh](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.langchain.com/wfh/32/33_2.png) [@wfh](https://forum.langchain.com/u/wfh)\
**Post date:** [April 29, 2026, 4:51pm UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622/4 "2026-04-29T16:51:40Z")

</div>

Anything in prod requires a proper DB, task queue, etc.; `dev` uses lightweight versions of these that aren’t designed for a distributed system.

---

<div class="post-metadata">

**Author:** ![wigging](https://yyz1.discourse-cdn.com/flex007/user_avatar/forum.langchain.com/wigging/32/2830_2.png) [@wigging](https://forum.langchain.com/u/wigging)\
**Post date:** [April 30, 2026, 3:10am UTC](https://forum.langchain.com/t/serving-an-agent-with-the-langgraph-cli-dev-command/3622/5 "2026-04-30T03:10:19Z")

</div>

So using `langgraph up` is considered a production deployment for a self-hosted server?
