// the find
dubinc/dub
The modern link attribution platform. Loved by world-class marketing teams like Framer, Perplexity, Superhuman, Twilio, Buffer and more.
Dub is a production-grade link shortener with built-in click analytics, conversion tracking, and affiliate program management. It's for teams that want Bitly-level functionality self-hosted, or want to build link attribution into their product via the API. At 100M+ clicks/month in production, the data pipeline decisions are grounded in real scale.
The analytics stack is the right call: ClickHouse via Tinybird handles high-cardinality click events without hammering MySQL, and Upstash Redis sits in front for rate limiting and deduplication. The open-core boundary is unusually clean — the `/ee` directory is a hard filesystem split, not scattered feature flags, so you can actually audit what you're getting for free. Turborepo monorepo is well-structured with proper workspace boundaries; the packages directory shares types and UI components without the usual circular dependency mess. The cron job surface area (fraud detection, domain renewal, commission aggregation) shows this was built to run unattended in production, not just demoed.
Self-hosting is technically possible but practically painful: you need PlanetScale (or a MySQL-compatible DB), Tinybird (no open-source substitute with the same API), Upstash, and Vercel's edge network for the redirect performance story — that's four managed services before you write a line of config. The affiliate/partner program features that make this interesting over plain Bitly are entirely in the EE tier under a commercial license. PlanetScale ended its free tier in 2024, so the default local dev path now assumes you're paying or running a MySQL emulator. The redirect endpoint is Vercel-optimized and will need rethinking if you want sub-100ms redirects on any other infra.