How to Setup your own URL Shortening Service

by Preetha 2012-09-13 12:52:26

URL shortening services like goo.gl, bit.ly, etc. provide small aliases for long web addresses thus making it easier for you to share complex links through email, IM, Twitter, etc.

The only problem with URL shortening services is that most of them don't have a solid business model yet so if they decide to shut shop in future, all your existing short links will become broken or point to non-existent 404 pages.

To prevent yourself from running into such a situation, you can consider setting up your own URL shortening service that will run on your own domain (or web server) and the short URLs will therefore resolve throughout the lifespan of your site.

Google Short URLs Service for Google Apps
Google provides an excellent URL shortening service but it's only available for sites that use Google Apps for Domains. Other than providing memorable shortcuts to web URLs, Google Short Links service also offers standard analytics so you can know the usage level (or click-throughs) of individual URLs.

You can either create custom aliases or let the Google App itself choose a short URL for your web address but unlike the TinyURL service that does a 301 redirect, Google Short URLs do a 302 temporary redirect so the link juice, PageRank, etc. aren't transferred to the original URL.

Tiny URLs created with Google Short Links offer another advantage - you can edit the underlying web page address so the short URLs will stay valid even if the underlying page has moved to a new location.

Run your own URL Shortening Service
Google Short Links are a perfect match for people who need a TinyURL like redirection service without involving any technical details. You don't need any web server space and there are no MySQL databases or PHP scripts involved but the only downside it that your site must be running on Google Apps.

If you need to set up redirection on a site that doesn't use Google Apps, try Shorty - it's a free MySQL + PHP scripts that you may either set on sub-domain or a sub-directory under your main website.

With Shorty, you get a simple web interface to create as well as manage all your existing short URLs. Just upload all the installation files to your Apache server and run _install.php from the web browser. It also provides stats for individual short URLs.

Tagged in:

536
like
0
dislike
0
mail
flag

You must LOGIN to add comments