Open-source URL shortener with branded links, custom domains, QR codes, and click, lead, and revenue tracking.
- Stars
- 25,123
- Forks
- 3,391
- Open issues
- 113
- Last commit
- 12 days ago
What is it?
Dub is a link attribution platform for marketing teams. It combines short links with click and conversion tracking, so teams can see which links drive signups or sales. It also includes an affiliate program module for managing partners and their referral links.
The project is built with Next.js, TypeScript, and Tailwind CSS. Data is stored in MySQL through Prisma, with Upstash Redis for caching and Tinybird for analytics. Authentication uses NextAuth.js, payments use Stripe, and email is sent through Resend.
The core is licensed under AGPLv3, and enterprise features in the /ee directory fall under a commercial license. The repository includes a self-hosting guide and a local development setup with a seed script.
Key features
- 01Creates short links and tracks clicks and conversions.
- 02Provides an affiliate program module for managing partners and referral links.
- 03Stores data in MySQL via Prisma ORM.
- 04Uses Upstash Redis for caching and Tinybird for analytics.
- 05Can be self-hosted, with a guide in the project docs.
Use cases
- Tracking which marketing campaign links lead to signups or purchases.
- Running an affiliate or partner program with referral links.
- Self-hosting a link management platform to keep data under your control.
Quick start
- 1
Follow the local development guide to set up your environment
- 2
Use the recommended Node v23.11.0 and pnpm 9.15.9
- 3
Install dependencies
pnpm install - 4
Build the project
pnpm build
Things to know
- The license is mixed: the core is AGPLv3, while the /ee enterprise directory requires a commercial license.
- It depends on many external services such as PlanetScale, Upstash, Tinybird, Stripe and Resend, so self-hosting takes setup effort.
- The README's local setup relies on linking to an external development guide rather than giving full steps inline.
In collections
Topics
FAQ
- What is dub.link?
- Open-source link attribution platform for short links, conversion tracking, and affiliate programs, built with Next.js and TypeScript. Dub is a link attribution platform for marketing teams. It combines short links with click and conversion tracking, so teams can see which links drive signups or sales. It also includes an affiliate program module for managing partners and their referral links.
- Is dub.link free to use? What license does it have?
- dub.link is open source under the Other license. Check the license terms before using it in commercial products.
- Is dub.link still maintained?
- Actively maintained. The last commit to dub.link was on Oct 27, 2026.
- What can I use dub.link for?
- Tracking which marketing campaign links lead to signups or purchases. Running an affiliate or partner program with referral links. Self-hosting a link management platform to keep data under your control.
- How do I install dub.link?
- Follow the local development guide to set up your environment Use the recommended Node v23.11.0 and pnpm 9.15.9 Install dependencies: pnpm install Build the project: pnpm build
- Where can I get dub.link?
- The source code and installation instructions are on GitHub: https://github.com/dubinc/dub.link
Summary generated by AI from the project's README. GitHub stats refresh daily.
Related projects
A self-hosted URL shortener written in PHP, letting you run your own short-link service with control over your data and stats.
A self-hostable link shortener with analytics that runs entirely on Cloudflare Workers, D1, and KV, with no traditional server.
Self-hostable URL shortener built with Laravel, Vue 3 and Inertia.js, with click analytics, custom domains and custom slugs.
Open-source DocSend alternative for sharing documents through secure data rooms with analytics and custom domains.
All-in-one self-hostable domain service platform combining short links, disposable email inboxes, subdomain DNS management, file storage and an open API, with an admin panel.