
Deploy Graphiti
Graphiti 0.31.2 REST API + MCP server, Neo4j on a volume, key auth, pinned
Just deployed
/data
Graphiti MCP
Just deployed
Just deployed
Deploy and Host Graphiti on Railway
Graphiti is Zep's open-source framework for temporal knowledge graphs. It turns chat messages, text and JSON into entities and facts, records when each fact was true, and lets AI agents search that memory with combined semantic, keyword and graph search. It is used as long-term memory for agents and assistants.
About Hosting Graphiti
This template deploys Graphiti 0.31.2 as three services that build from one public GitHub repo, each pinned to an official image by version and digest. Graphiti is the REST API, with Swagger docs at /docs. Graphiti MCP is the MCP server, at /mcp over streamable HTTP. Neo4j 5.26 LTS keeps the graph on a volume and is reachable only on the private network. Railway generates the Neo4j password and a GRAPHITI_API_KEY, which both public services require as a bearer token. The only value you enter is an OpenAI API key, which Graphiti uses for extraction and embeddings.
Common Use Cases
- Long-term memory for coding agents and chat assistants through MCP (Claude Code, Cursor, VS Code)
- Turning conversations and business data into a searchable, time-aware knowledge graph
- Retrieval for agent apps that need facts and relationships rather than raw text chunks
Dependencies for Graphiti Hosting
- An OpenAI API key (the MCP service can also use an OpenAI-compatible endpoint through
OPENAI_API_URL) - Neo4j 5.26, included in this template with a persistent volume
Deployment Dependencies
- Graphiti source and docs: https://github.com/getzep/graphiti
- Graphiti 0.31.2 release: https://github.com/getzep/graphiti/releases/tag/v0.31.2
- Template repo (Dockerfiles, changelog): https://github.com/aalfath/graphiti-railway-template
- Neo4j Docker docs: https://neo4j.com/docs/operations-manual/5/docker/
Implementation Details
After the deploy, open the Graphiti service's Variables tab and copy GRAPHITI_API_KEY. Connect an MCP client to the Graphiti MCP domain:
claude mcp add --transport http graphiti https://YOUR-MCP-DOMAIN/mcp \
--header "Authorization: Bearer YOUR-GRAPHITI-API-KEY"
Or call the REST API, for example POST https://YOUR-API-DOMAIN/messages to add messages and POST /search to query facts, with the same Authorization header. In the Swagger UI at /docs, click Authorize. /healthcheck and /health answer without a key.
Optional variables: MODEL_NAME (the extraction model on both services), GRAPHITI_GROUP_ID (the default MCP namespace, main), GRAPHITI_TELEMETRY_ENABLED=true (opt in to telemetry, which is off here), and Neo4j memory settings such as NEO4J_server_memory_heap_max__size (default 1G). Embeddings use text-embedding-3-small at 1536 dimensions. Don't change the embedding size once the graph holds data. If you need only one interface, delete the other Graphiti service. The graph is not affected.
Updates: new Graphiti versions arrive as an "update available" notice in your Railway project when the template repo changes. Read its CHANGELOG.md before you apply one, and back up the Neo4j volume before a major Neo4j upgrade.
Why Deploy Graphiti on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Graphiti on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content
Graphiti MCP
aalfath/graphiti-railway-templateOPENAI_API_KEY
Your OpenAI API key. Graphiti uses it for entity extraction (LLM) and embeddings. The MCP service reuses it.

