I wanted a link shortener with no vendor lock-in and no monthly SaaS bill. Here’s the whole stack, soup to nuts, running on a $4/month VPS.

The stack

  • A small Go service that reads/writes to SQLite
  • Caddy in front for automatic HTTPS
  • Docker Compose to wire the two together and make deploys a docker compose up -d

What surprised me

SQLite handled the load without complaint — this isn’t a high-traffic service, and WAL mode alone was enough to avoid any lock contention between reads and writes.

Backups

A cron job sqlite3 .backups the database nightly to a second, cheaper VPS over Tailscale. Total cost for the whole thing: under $5/month, and one command to restore.