I have a love hate relationships with short URLs, they are great for space saving and adding a custom touch, but their obscurity can confuse and introduce risk for people.
In this article, I will explain what short links are, how to use them like a pro, avoid the dangers and take advantage of them for your business or online prescience.
What are short URLs?
Short URLs are desirable because they are ‘short,’ the primary goal behind a short URL is to reduce the length of the original link.
What are the benefits?
- They give you an opportunity to brand your links.
- Custom branded short URLs can be used as an opportunity to build trust with your users.
- You can use them to gain more insights into visitor behavior with analytics.
- You can use them in more static scenario’s and change the destination URL later. Example: you could print a URLs on a poster and change the URL later without needing a reprint.
What are the dangers of a short URL?
In some circumstances a short URL can mask where it leads to. It’s also possible to link you to a malicious or hidden URL.
A bad actor could mask a URL using a short URL that could capture information about you, or direct you to a page you didn’t intend to visit.
Unless your recognise and trust the sender, treat ShortURLs in unsolicited communications with extreme caution.
Scam Watch Australia revealed last year (2021) that a campaign of scams had been circulating distributing ‘flubot,’ to infect Android phones using URLs in unsolicited text messages. Many claiming to be missed deliveries etc.
How can I check a Short URL and know where it leads?
The best way to check where a short URL leads is to use a service that can expand the link safely for you.
On mobile or desktop you can use ‘CheckShortURL’ a free service where it does the lifting for you, revealing the long URL of the short link.
How Can I Run My Own URL Shortener?
What you’ll need,
- Your own domain name. Preferably short as possible and resembles something close to your brand.
- Web hosting that supports MySQL & PHP (Look for cPanel hosting)
- an installation of YOURLS. (it’s free)
Estimated monthly cost? $4 if you can find the right hosting.
You will also need to manage the installation yourself, this means periodically upgrading the software to latest version.
More info please?
- Start by registering a domain name with a domain provider. Look around as the price can vary between registrars.
- You will also need web hosting, shared hosting is a great cost effective option for this type of project. It cost a few dollars per month and is usually available for sale from the same company you purchased the domain from.
- Update your name servers so they match those for your hosting. In most circumstances, if you have purchased your webhosting with your domain, this will already be configured for you.
- Wait, DNS records can take a while to update, depending on how frequently your ISP updates DNS, it could take minutes to hours for the changes to take affect.
- Download a zip file of YOURLS from the project website and upload the files to the public_html folder in your cPanel hosting.
- Create a MYSQL database, name it something like ‘YOURLS’ etc.
- Then create a MYSQL user with a strong password.
- Add the user you just created to the database you created earlier.
- Write the database name, username and password down, I suggest using a sticky note, or a notepad on your computer to temporarily store them.
- Find the file called ‘config-sample.php,’ rename this file so it reads ‘config.php’ and open the file in the editor.
- Enter your username and password for MySQL
- Enter your sites URL
- Create your username and password following the conventions set out in the config sample.
- Look for a line that says ‘replace this text’ and replace with random text. This will secure your installation.
- Hit save when done, and visit the base URL or your domain name.
If you can log in, congratulations it’s setup and working.
That wraps up my two cents of short URLs.