---
title: "Deploy AnythingLLM Private Docs Chat"
description: "Password-protected AnythingLLM with persistent docs, chats and settings"
category: "AI/ML"
url: https://railway.com/deploy/anythingllm-private-docs-chat
---

# Deploy AnythingLLM Private Docs Chat

Password-protected AnythingLLM with persistent docs, chats and settings

**[Deploy AnythingLLM Private Docs Chat on Railway](https://railway.com/template/anythingllm-private-docs-chat)**

Machine-readable deploy manifest (JSON, validated by TemplateCI): https://railway.com/deploy/anythingllm-private-docs-chat/manifest.json

- **Creator:** Protemplate
- **Category:** AI/ML
- **Total deploys:** 2

## Template content

### AnythingLLM https://avatars.githubusercontent.com/u/134426827?v=4

- **Image:** mintplexlabs/anythingllm:railway-1.19.0
- **Health check:** /api/ping
- **Public domain:** Yes

## Documentation

# Deploy and Host AnythingLLM on Railway

AnythingLLM is an all-in-one private ChatGPT for your documents. Upload PDFs, Word files, web pages and code, organize them into workspaces, and chat with them using any LLM: OpenAI, Anthropic, OpenRouter, Ollama or any OpenAI-compatible endpoint. It also ships AI agents, MCP tools, an embeddable chat widget and a developer API.

## About Hosting AnythingLLM

This template runs the official `mintplexlabs/anythingllm:railway-1.19.0` image, the build AnythingLLM publishes for Railway, with one volume at `/storage`. That image keeps the SQLite database, your settings, uploaded documents, LanceDB vectors and the built-in embedding model under `/storage`, so everything survives redeploys. Templates built on the generic image keep the database and settings on the container disk and lose them on every redeploy.

The instance is password protected from the first boot. A fresh AnythingLLM with no password is open to whoever loads the URL first, who can then set their own password and lock you out. This template generates `AUTH_TOKEN` (the password), `JWT_SECRET`, `SIG_KEY` and `SIG_SALT` for you, so anonymous visitors only ever see the login screen.

It boots with zero API keys: the native embedder and LanceDB run inside the container. You only add an LLM provider key when you want to chat.

## Common Use Cases

- **Chat with your documents**: private RAG over PDFs, DOCX, TXT, CSV, web pages and GitHub repos
- **Team knowledge base**: turn on multi-user mode for admin, manager and user roles per workspace
- **AI agents**: web browsing, scraping, file and SQL tools, MCP servers
- **Embeddable chat widget** for your website, scoped to one workspace
- **Developer API** to create workspaces, upload documents and chat from your own apps

## Dependencies for AnythingLLM Hosting

- **Railway volume** at `/storage` (included)
- **LLM provider**: optional at boot, required to chat. Pick it in the onboarding screen
- **No database service required**: SQLite and LanceDB live on the volume

### Deployment Dependencies

- [AnythingLLM Docker docs](https://docs.anythingllm.com/installation-docker/quickstart)
- [Configuration and env vars](https://docs.anythingllm.com/configuration)
- [AnythingLLM GitHub repository](https://github.com/Mintplex-Labs/anything-llm)

### Implementation Details

```env
PORT=3001
SERVER_PORT=3001
STORAGE_DIR=/storage
RAILWAY_RUN_UID=0
AUTH_TOKEN=${{secret(32)}}
JWT_SECRET=${{secret(32)}}
SIG_KEY=${{secret(32)}}
SIG_SALT=${{secret(32)}}
ANYTHINGLLM_CHROMIUM_ARGS=--no-sandbox,--disable-setuid-sandbox
```

**First steps after deploy**

1. Wait for the healthcheck on `/api/ping` to pass (first boot runs database migrations).
2. Copy `AUTH_TOKEN` from the service's Variables tab and open your Railway domain. Enter it as the password.
3. Finish onboarding: pick your LLM provider and paste its API key. Embeddings and the vector database are already set up.
4. Create a workspace, upload a document and start chatting.
5. Optional: Settings, Users enables multi-user mode with your own admin account. For API access, create a key under Settings, Developer API and see `/api/docs`.

To change the password, edit `AUTH_TOKEN` in Railway and redeploy. A password changed inside the app reverts to that variable on the next deploy. Never rotate `SIG_KEY` or `SIG_SALT` after first boot. Keep one replica: SQLite and the volume do not support replicas. Plan on 2 GB of RAM (Hobby plan or higher).

## Why Deploy AnythingLLM 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 AnythingLLM on Railway, you get a pinned, health checked, password protected document chat with persistent storage, generated secrets and managed SSL.


## Similar templates

- [Chat Chat](https://railway.com/deploy/-WWW5r) — Chat Chat, your own unified chat and search to AI platform.
- [Weaviate](https://railway.com/deploy/weaviate-1) — Vector database with hybrid search and an API key-protected API
- [Möbius v0.1 Personal AI OS](https://railway.com/deploy/mobius-v01-personal-ai-os) — Self-hosted AI agent that builds and runs apps for you, with memory.

Open this page in a browser: https://railway.com/deploy/anythingllm-private-docs-chat
