How to Self-Host Ghost Blog on a VPS
Ghost is a fast, focused publishing platform with built-in memberships and newsletters. Install it on a VPS with Docker and HTTPS in under half an hour.

Ghost is a modern publishing platform built for writers and creators, with native memberships, paid subscriptions and email newsletters. Self-hosting means no monthly Ghost(Pro) fee and full control of your data. This guide installs Ghost with Docker, connects a domain, and secures it with HTTPS.
Ghost vs WordPress
Ghost is lighter and faster than WordPress and comes with subscriptions and newsletters built in — but it does far less. If you need a plugin ecosystem, forms and page builders, WordPress is the better fit; see how to host WordPress on a VPS. If you want a clean, fast blog or a paid newsletter, Ghost shines.
Prerequisites
- A VPS with at least 1 GB RAM and Docker installed — run Docker on a VPS.
- A domain with an A record, e.g.
blog.example.com.
Deploy Ghost with Compose
Ghost needs a MySQL database. We'll add Caddy for automatic TLS.
mkdir -p ~/ghost && cd ~/ghost
services:
db:
image: mysql:8
restart: unless-stopped
environment:
- MYSQL_ROOT_PASSWORD=change-me-root
- MYSQL_DATABASE=ghost
- MYSQL_USER=ghost
- MYSQL_PASSWORD=change-me-db
volumes:
- db:/var/lib/mysql
ghost:
image: ghost:5-alpine
restart: unless-stopped
depends_on:
- db
environment:
- url=https://blog.example.com
- database__client=mysql
- database__connection__host=db
- database__connection__user=ghost
- database__connection__password=change-me-db
- database__connection__database=ghost
volumes:
- ghost:/var/lib/ghost/content
caddy:
image: caddy:2
restart: unless-stopped
ports:
- "80:80"
- "443:443"
volumes:
- ./Caddyfile:/etc/caddy/Caddyfile
- caddy_data:/data
depends_on:
- ghost
volumes:
db:
ghost:
caddy_data:
Caddyfile:
blog.example.com {
reverse_proxy ghost:2368
}
docker compose up -d
Set up your admin account
Ghost's admin panel lives at /ghost. Open https://blog.example.com/ghost, create your account, and name your publication.

Connect email for newsletters
Ghost's membership emails need a mail provider. In Settings → Email newsletter, add transactional SMTP credentials (a dedicated sending service is best for deliverability). Getting email DNS right matters here — SPF, DKIM and DMARC explained walks through the records that keep newsletters out of spam.
Pick a theme and start writing
Ghost ships with the clean Casper theme; browse the marketplace for more, or upload your own. The editor is distraction-free and supports cards for images, embeds, code and calls to action. Publish, and your post is live on a fast, cache-friendly page.
Firewall and backups
sudo ufw allow OpenSSH
sudo ufw allow 80/tcp
sudo ufw allow 443/tcp
sudo ufw enable
Back up the ghost content volume (images, themes) and dump the database regularly. Store copies off-server.
Memberships, newsletters and Stripe
Ghost's standout feature is native paid membership. Under *Settings → Membership* you can enable free and paid signups, then connect Stripe to accept subscriptions — Ghost takes no cut beyond Stripe's own fees. Create tiers (say, a free newsletter and a paid supporter tier) and gate individual posts to members or paid members with each post's *Access* setting. Every new post can automatically go out as an email newsletter to the right audience, turning your blog into a full publishing-and-subscription business with no third-party platform in the middle.
Themes, SEO and speed
Ghost pages are fast out of the box and produce clean, SEO-friendly markup with automatic sitemaps, canonical URLs and structured data. To customise the look, edit the active theme or install another from the marketplace; theming uses the approachable Handlebars templating language. Because Ghost caches so well behind your reverse proxy, even a modest VPS serves traffic spikes comfortably. Keep the platform current with a quick pull:
cd ~/ghost
docker compose pull && docker compose up -d
Importing content and growing an audience
Moving from another platform? Ghost imports content from WordPress and others via its migration tools — export from your old site, use the Ghost admin *Settings → Migration* importer (or the WordPress plugin), and your posts, images and authors come across. After importing, spot-check a few posts for formatting and fix internal links.
Because Ghost is built for publishing, the growth tools are first-class: SEO metadata per post, automatic sitemaps and structured data help you rank, while built-in newsletters mean every post can reach subscribers' inboxes directly. Add a signup form to your theme, connect your email provider, and you're building an owned audience that no algorithm sits between. For deliverability, make sure your sending domain's SPF, DKIM and DMARC records are correct — the email DNS guide covers exactly what to add.
FAQ
Is self-hosting Ghost cheaper than Ghost(Pro)?
Usually, yes — a small VPS costs a fraction of Ghost(Pro)'s monthly plans, especially as your member count grows. The trade-off is that you handle updates and backups.
Can Ghost handle paid memberships?
Yes. Ghost has native membership and subscription support with Stripe integration, plus newsletters — no plugins required.
Does Ghost need a lot of resources?
No. It's efficient — 1 GB RAM runs a personal blog comfortably. Traffic spikes are handled well because Ghost's pages cache nicely behind a reverse proxy.
How do I point my domain at Ghost?
Add an A record for your subdomain pointing at the VPS IP, then set that domain in the url variable. See how to point a domain to your VPS.
Launch your publication on a fast NVMe VPS with full root access, or pick a plan on the pricing page.