Self-Hosting

Own Your Services

Every month you pay for cloud storage, photo backup, a password manager, streaming, and more — and every one of those companies holds your data. Self-hosting means running those services yourself, on a small Linux server at home. It's private, it's cheaper over time, and it's the best hands-on Linux, networking, and security training there is.

Each guide below is a complete, copy-and-paste walkthrough. They all follow the same pattern — one folder and one compose.yaml per app — so once you've done two or three, the rest feel familiar.

New here? Do the Foundations in order first (at least 1, 3, 4 and 5). Every app guide assumes them.

Suggested Build Order

  1. Week 1 — The server: Foundations → Portainer
  2. Week 2 — Access & safety: Reverse proxy + HTTPS → Tailscale → Backups
  3. Week 3 — Quick wins: Pi-hole → Vaultwarden → Homepage
  4. Week 4 — The big ones: Immich → Jellyfin → Nextcloud
  5. Then: monitoring, and whatever apps you'll actually use.

Foundations (Do These First)

The server, remote access, HTTPS, backups, and monitoring that every app relies on.

Files & Photos

Replace Google Drive, Dropbox, Google Photos and iCloud.

Media

Replace Netflix, Spotify, and Audible-style apps — for media you own.

Security & Privacy

Passwords and ad blocking for the whole family.

Home & Life

Everyday tools for the household.

Developer Tools

Version control for your code and your homelab.

Port Map: Every App on One Server

These are the host ports used in the guides, chosen so every app can run on the same machine without clashing. Keep this table updated if you add your own apps.

AppPort(s)Suggested name
Nginx Proxy Manager80, 443, 81 (admin)—
Pi-hole or AdGuard Home53 + 8081 (Pi-hole) / 53 + 3004 + 8083 (AdGuard)pihole / adguard
Homepage3000home
Uptime Kuma3001status
Forgejo3002, 2222 (SSH)git
Grafana / Prometheus3003 / 9090grafana
Paperless-ngx8000docs
Nextcloud AIO8080 (admin), 11000 (app)cloud
Vaultwarden8082vault
FreshRSS8084rss
Jellyfin8096jellyfin
Home Assistant8123 (host network)ha
Syncthing8384, 22000, 21027 (host network)—
Immich2283photos
Navidrome4533music
Portainer9443portainer
Mealie9925recipes
Audiobookshelf13378books
wg-easy (WireGuard)51820/udp, 51821wg

Check what's already in use on your server with sudo ss -tulpn.

The Five Rules of Safe Self-Hosting

  1. Backups before data. Don't move photos or passwords in until restic is running and you've tested a restore.
  2. Don't open ports. Use Tailscale to reach things remotely. Forward a port only when a guide says so and you understand why.
  3. Update regularly. Once a month: docker compose pull && docker compose up -d in each folder, plus sudo apt update && sudo apt full-upgrade. Read release notes for Immich and Nextcloud first.
  4. Unique passwords + 2FA on every admin page, stored in Vaultwarden — plus a paper copy of the master password.
  5. Keep secrets out of screenshots and Git. .env files, API keys, and tokens never go in a video, a blog post, or a repository.

Start Building

Foundations 1: Build Your First Home Server →