Installation Guide
Installation guide
Deploy ThinCMS on a VPS, Vercel, Docker, or your local machine. Every option uses the same codebase and the same SQLite database — pick the environment that fits your workflow.
Deployment options
VPS deployment
Full control on any Ubuntu, Debian, or similar Linux server. Best for agencies managing multiple client sites. Predictable monthly cost.
Vercel deployment
Zero-config deployment with automatic builds and preview URLs. Great for solo sites and developer portfolios. Note: persistent SQLite requires additional configuration.
Docker deployment
Consistent environments across dev, staging, and production. Works with Docker Compose, Kubernetes, or any container orchestrator.
Local development
Run ThinCMS on your local machine for theme development, plugin testing, or learning the system. Quick setup with hot reloading.
VPS deployment
A VPS gives you full control over the environment. ThinCMS runs well on minimal hardware — a $5–10/month server is more than enough for most single-site installations. Agency installations serving 10–50 sites typically need 2–4 GB of RAM.
System requirements
| Component | Minimum | Recommended |
|---|---|---|
| CPU | 1 vCPU | 2 vCPU |
| RAM | 512 MB | 1–4 GB |
| Disk | 1 GB + media | 10 GB SSD |
| OS | Ubuntu 20.04+ | Ubuntu 22.04 LTS |
| Node.js | 18.x | 20.x LTS |
Step-by-step
$ curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
$ sudo apt-get install -y nodejs
# Clone and install
$ git clone https://github.com/thincms/thincms.git /opt/thincms
$ cd /opt/thincms
$ npm install --production
# Configure environment
$ cp .env.example .env
$ nano .env # Set THINCMS_API_KEY and other options
# Initialize database and build
$ npx prisma db push
$ npm run build
# Start with PM2 (recommended process manager)
$ npm install -g pm2
$ pm2 start npm --name "thincms" -- start
$ pm2 save
$ pm2 startup
We recommend using Nginx or Caddy as a reverse proxy for SSL termination and static file serving. Caddy is the simplest option — it handles HTTPS automatically.
Caddy reverse proxy config
reverse_proxy localhost:3000
}
Vercel deployment
Vercel provides the fastest path to a live ThinCMS site. Push to GitHub and Vercel builds and deploys automatically. Note that persistent SQLite on serverless requires a solution like Turso or LiteFS — see the notes below.
$ npm install -g vercel
# Deploy from your project directory
$ vercel
# Set environment variables
$ vercel env add THINCMS_API_KEY
Important: SQLite on serverless
Vercel's serverless functions don't have persistent filesystems. For production use, you'll need a persistent SQLite solution like Turso (SQLite-compatible edge database) or deploy to Vercel with a VPS-hosted database. For development and preview deployments, the default SQLite file works fine.
Docker deployment
Docker provides consistent environments across all stages. The included Dockerfile and docker-compose.yml handle everything.
Using Docker Compose
$ git clone https://github.com/thincms/thincms.git
$ cd thincms
$ cp .env.example .env
$ docker compose up -d
The SQLite database file is stored in a named volume, so your data persists across container restarts and rebuilds.
docker-compose.yml
services:
thincms:
build: .
ports:
- "3000:3000"
volumes:
- thincms-data:/app/prisma
- thincms-uploads:/app/public/uploads
env_file: .env
restart: unless-stopped
volumes:
thincms-data:
thincms-uploads:
Local development
For theme development, content experimentation, or just getting familiar with ThinCMS. Follow the Getting Started guide — the development server includes hot reloading so changes appear instantly.
$ cd thincms
$ npm install
$ cp .env.example .env
$ npx prisma db push
$ npm run dev
Environment variables
ThinCMS is configured via environment variables. Here are the key settings.
| Variable | Required | Description |
|---|---|---|
| THINCMS_API_KEY | Yes | Authentication key for REST API and MCP server |
| DATABASE_URL | No | SQLite file path (default: file:./prisma/dev.db) |
| NEXTAUTH_SECRET | Prod | Secret for session encryption in production |
| NEXTAUTH_URL | Prod | Your site's full URL (e.g., https://example.com) |
| PORT | No | Server port (default: 3000) |
Backup and restore
Because ThinCMS uses SQLite, backups are as simple as copying a single file. No database dumps, no complex export scripts.
$ cp prisma/dev.db backups/thincms-$(date +%Y%m%d).db
# Restore
$ cp backups/thincms-20260309.db prisma/dev.db
$ pm2 restart thincms
For automated daily backups, a simple cron job works perfectly. Back up to a remote location (S3, rsync to another server) for disaster recovery.
Ready to build?
You've deployed ThinCMS. Now explore the full API to build custom integrations and workflows.
