Deploy Deft
Workspace where people and AI agents share chat, tasks and docs
Postgres
Just deployed
/var/lib/postgresql/data
Just deployed
/data
Deploy and Host Deft on Railway
Deft is a self-hosted workspace where people and AI agents work side by side: team chat in spaces and threads, tasks and projects, a knowledge base of pages, approvals for what agents want to do, and MCP connections so your agents (and Claude, Codex or Cursor) can read and act on the workspace. It is licensed AGPL-3.0. This template runs Deft 0.3.0-preview.157 on Railway with Postgres and pgvector, the owner account ready on the first boot.
This is a community template, not made or supported by the Deft authors. Deft is still in preview, with frequent releases.
About Hosting Deft
Before deploying, set ADMIN_EMAIL to your email. Deploy, wait for the green check (the first boot creates the database, which takes a minute or two), and open the Railway domain. Sign in with ADMIN_EMAIL and the generated ADMIN_PASSWORD, both on the Deft service's Variables tab. Change the password in your profile afterwards; the variable is only used on the first boot.
Why the owner is created for you: a fresh Deft server makes whoever signs up first the owner of the workspace. On a public address that could be a stranger, so this template creates the owner from your variables before the site opens. After that, direct sign-up is closed and people join through invite links you create under Settings > Members.
AI features: paste provider keys under Settings > AI (Anthropic, OpenAI, OpenRouter, or an Ollama server you run). You can also set ANTHROPIC_API_KEY, OPENAI_API_KEY or OPENROUTER_API_KEY on the Deft service as fallbacks. Without a key, chat, tasks and pages work and the AI features stay off.
Your data: messages, tasks, pages and settings are in the Postgres service; uploaded files are on the Deft service's volume at /data. Redeploys keep both, and the database is upgraded automatically when Deft is.
Custom domain: add it under the Deft service's Settings > Networking, set PUBLIC_URL=https://deft.example.com and redeploy.
Telemetry: like upstream, Deft sends one anonymous ping to get.deft.ing when the workspace is created and when someone joins (an install ID, the event, the version, the time). Set DEFT_TELEMETRY=off on the Deft service to turn it off.
Common Use Cases
- A team chat and task tracker where AI agents take work, report back and ask for approval
- A shared knowledge base that your agents read and update over MCP
- Giving Claude, Codex or Cursor scoped access to a team's tasks and docs
- A self-hosted alternative to Slack plus Linear plus Notion for a small team
- Trying agent workflows on your own data without a hosted service
Dependencies for Deft Hosting
- Postgres with pgvector (included)
- For AI features: an API key from Anthropic, OpenAI or OpenRouter, or your own Ollama server
Deployment Dependencies
Implementation Details
- Services: Deft (its web app and API in one container, behind Caddy on one port) and Postgres 16 with pgvector on Railway's private network.
- Database: a fresh database gets Deft's tables and seed data on the first boot; every later boot runs Deft's own upgrade step before the app starts.
- Secrets: the owner password, both token secrets, the encryption key for stored AI keys and the database password are generated per deploy. Never change
ENCRYPTION_KEYafter saving AI keys, or Deft can't read them. - Never crash-looping on a variable: if a secret is too short,
PUBLIC_URLorADMIN_EMAILis malformed, or Postgres can't be reached, the service shows a page saying what to fix instead of restarting over and over, and the deploy logs say the same. - Image: upstream's official
ghcr.io/maneek21/deft:0.3.0-preview.157, pinned and unmodified, plus a small entrypoint and Caddy. - Memory: MEMORY_PLACEHOLDER
Why Deploy Deft 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 Deft 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
Postgres
pgvector/pgvector
