Self-hosted · Flask + PostgreSQL

Short links with an expiration date.

Sniplink is a self-hosted URL shortener. Paste a long URL, get a short alias that redirects instantly, and track hit counts, last access time, and referrers per link — all from your own server, your own database.

The X Factor

The two features Bit.ly puts behind a paywall

Most shorteners stop at “make it short.” Sniplink adds the two things people actually pay for elsewhere — links that expire on their own, and QR codes that don't cost extra.

01 · Expiry

Link expiry, on your terms

Every link can carry an expiration rule — after N days, after N clicks, or both. Once a link crosses its limit, Sniplink stops redirecting and serves a clean, branded “expired” page instead of leaving a dead link out in the world.

  • Expire by absolute date (e.g. 7, 30, 90 days)
  • Expire by click count (e.g. after 500 hits)
  • A scheduled check flips status without manual cleanup
02 · QR Codes

QR codes, one click, free

Every short link gets an auto-generated QR code the moment it's created, ready to drop into a poster, slide deck, or packaging insert — no watermark, no paywall, no "upgrade to download."

  • Generated instantly via the qrcode library
  • Downloadable as PNG straight from the dashboard
  • Scans through to the same expiry-aware redirect
Dashboard

Every link, its clicks, and its clock

Paste a URL, optionally set an expiry, and Sniplink hands back a short link plus a QR code. The dashboard tracks hits, last access, referrer, and expiry status for everything you've created.

🔗https://example.com/a/very/long/campaign-url?utm_source=…
expires in 30 days
snip.link/launch-igActive
→ instagram.com/p/campaign-launch-2026via instagram.com · last hit 4 min ago
1204clicks
expires in 12 days
snip.link/pdf-onepagerExpires soon
→ drive.google.com/file/d/onepager.pdfvia direct · last hit 2 hrs ago
487clicks
47 / 500 clicks used
snip.link/promo-octExpired
→ shop.example.com/promo/octobervia twitter.com · last hit 19 days ago
2031clicks
expired 3 days ago
Every short link ships with a scannable QR codeGenerated server-side with the qrcode library the instant you shorten a URL — download it as a PNG and it's yours, no subscription required.
Built with
FlaskSQLiteJinja2qrcode302 RedirectsScheduled Expiry ChecksPython 3
Run it

Up and running in three commands

Sniplink runs locally as a Flask app backed by SQLite — no external services, no signup, no API keys.

zsh — sniplink
# install dependencies
$ pip install flask qrcode

# start the server
$ python app.py

# open the app locally
→ http://localhost:5000

That's it — paste a URL, set an optional expiry, and Sniplink hands back a short link and QR code from the local Flask app on port 5000.