
YOURLS
Self-hosted PHP URL shortener with stats and plugins
YOURLS runs on your server as PHP scripts that create short links on your domain. It offers click analytics, an API, bookmarklets, and a plugin architecture.
Bitly by Bitly is a commercial product. These open-source projects say they can replace it.
The most popular open-source alternative to Bitly is YOURLS, with 12.3k GitHub stars. Other open-source alternatives to Bitly are Kutt, Sink, Shlink and Lua.sh (1 more below). Most Bitly alternatives here are Marketing & Customer Engagement tools. None of these projects names Bitly itself, but each does the same job; its own description is shown under it.
Stars and activity updated 27 November 2026.
These projects don't call themselves a Bitly alternative, but two independent checks of their own description found they do the same main job.

Self-hosted PHP URL shortener with stats and plugins
YOURLS runs on your server as PHP scripts that create short links on your domain. It offers click analytics, an API, bookmarklets, and a plugin architecture.
“YOURLS is a set of PHP scripts that will allow you to run Y our O wn URL S hortener, on your server.”

Self-hostable modern URL shortener with custom domains and statistics
Kutt is an open-source URL shortener with custom domains, link passwords and expiry, private statistics, an admin page and a REST API. It runs on Node.js with SQLite, Postgres or MySQL.
“Kutt is a free and open source URL shortener with custom domains and stats.”

Serverless link shortener with analytics, running entirely on Cloudflare
Link shortener with built-in click analytics that runs on Cloudflare's serverless platform. It targets individuals and small teams who want a simple self-hosted shortener with custom slugs, link controls and a dashboard.
“A Simple, Speedy, Secure, and Serverless Link Shortener with Analytics, Running Entirely on Cloudflare.”

Self-hosted PHP URL shortener with CLI and REST API
Shlink is a self-hosted URL shortener that serves short links under your own domains. It offers a command line, a REST API and a web client, and collects anonymized visit statistics with geolocation.
“A PHP-based self-hosted URL shortener that can be used to serve shortened URLs under your own domain.”

Open-source URL shortener with analytics and custom domains
Lua.sh is an open-source URL shortener for individuals and teams. It offers custom domains, custom slugs, link expiration and click analytics, and it can be self-hosted or used as a cloud service.
“Open-source, next-generation, and scalable URL shortener designed for modern teams.”

Open-source URL shortener with click, lead and revenue analytics
Slugy is an open-source link management tool for creating branded short links on custom domains, with QR codes and analytics that attribute signups and sales to the links that drove them.
“Open-source link management that tracks clicks, leads, and revenue.”
Yes. 6 open-source projects can replace Bitly, for example YOURLS, Kutt and Sink. They do the same job as Bitly, as their own documentation describes.
YOURLS (12.3k GitHub stars) is the most popular open-source alternative to Bitly on GitHub. The best choice depends on your needs: compare them side by side, for example YOURLS vs Kutt.
All of the 6 projects listed here are free to use under an open-source license, with no license fee: 4 permissive (such as MIT), 2 copyleft (such as AGPL-3.0). Running software on your own server still costs hosting and upkeep, and many projects also sell a hosted version.