Not so long ago, as part of working on a large project, I had to face the need to launch a URL shortening service on my own domain. I offer to the attention of a respected habrapublichki the result of the study
Domain selection
Solutions on someone else's hosting
Solutions on your hosting
Overview of yourls system
Domain selection
Here they used (and recommend everything) the Domainr service. The essence is simple: you enter your domain, the service offers possible abbreviations, immediately indicating the status of the corresponding domain.
Solutions on someone else's hosting
The first on the list was bitly.pro . They say good service - but, unfortunately, an invite to it, had to wait too long.
awe.sm - according to the statements, provide API, detailed analytics, uptime guarantee and SLA.
budurl - Enterprise edition allows you to use your domain. Provide real-time analytics and statistics.
XR.COM is a very “basic” service, but if you just need to shorten links and do not need statistics, then xr.com should suit you.
Google Short Links - shortened URL is available as part of Google Apps For Your Domain. So far, still in Labs, but it works quite stably.
Peashoot is a tool for managing social media campaigns using your own shortened URLs.
su.pr - StumbleUpon allows you to use their short link service on your domain, but you will also need to install their script on your own.
Solutions on your hosting
YOURLS PHP script is a set of several scripts that use the classic combination of PHP + MySQL. Our choice.
Movable Type script - if you have a Movable Type blog, you can use this system.
Overview of yourls system
We chose YOURLS: Your Own URL Shortener. Installing the system is extremely simple and consists of editing the config, creating the base and placing the files. The script will do everything else itself. You can work with the system through the administrative interface (ie, manually create / edit / delete links), a plugin for WordPress or an API. What API can do:
Generate a short link in plain text format or in XML / JSON.
"Decrypt" transmitted short link
Show statistics by reference
Show general system statistics
Generate a unique link each time or use the existing ones in the database (you can create links with meaningful text)
For access, a login / password pair or generated signature-string is used.