What is Hotlinking and Why is it Bad?

Faizan R.
By -
0

Hotlinking — also known as “inline linking” or “direct linking”— is the practice of using an <img> tag in another website to display images, video, and audio files hosted on other websites. Even though it might appear to be innocent on the surface, hotlinking can negatively impact so many aspects of owning original content. In this article, we will see what hotlinking exactly is, Why it is considered as evil, and how you can prevent your website from it.

What is Hotlinking and Why is it Bad

Understanding Hotlinking

Hotlinking is the act of embedding multimedia content straight from another site into your own page. That means if a website (let's say Website A) hosts an image and another webpage (say, Website B) is using the link to that hosted image in order to display it on their site; then this is called hotlinking. When one of the users visits Website B and sees that image, it will load from Website A's server, using its bandwidth, which can be a big problem for the site owner as costs become higher or, in the worst case scenario, the website might even go down.

Why is Hotlinking Bad?

Slurping Bandwidth

Hotlinking's simplest and most direct effect is the theft of bandwidth. Bandwidth is the amount of data that a server delivers to users. A website hotlinking to an image or video hosts all of the bandwidth from the original site without permission. The trick here is that since [site A] and the users on [site B] do not know of each other's existence, all the bandwidth required to serve images from [site B]'s community takes place invisibly, effectively increasing the hosting load for the original owner if their linked content becomes attractive.

Rising Server Load

Hotlinking can bloat the servers of an original site heavily. If hotlinking to the same image or video is done by more external sites, requests will be handled and processed on the server that hosts the original content, which can slow down your site or even lead it to crash.

Legal Issues

You can even get into legal problems because hotlinking others' images directly to your site is considered stealing. Copyright infringement is using someone else's creative works (pictures, posts, text) in your content without getting the original creator's permission. If they do, the content owners are entitled to sue the platforms such that in some cases, sites may be subjected to fines or other penalties.

Cloudflare Hotlink Protection

Loss of Control and Ownership

By hotlinking content on a website like an image, you lose your ownership over that media. The original owner of the content can change or remove a file at any time, resulting in broken links on your site. For example, they could replace the hotlinked image with something offensive or unrelated.

Negative SEO Effect

Hotlinking can cause search engines to penalize websites. This can result in lower rankings, making it difficult for users to find your site online.

Protect Your Site from Hotlinking

Cloudflare Hotlink Protection

One of the quickest ways to secure your site from hotlinking is with Cloudflare Hotlink Protection. This feature prevents others from directly embedding your media files, saving bandwidth and speeding up your website.

Using .htaccess File

You can use the .htaccess file to stop hotlinking. You can block it by specifying rules in this file, so all sites will be blocked from hotlinking your content. An example of how to do so is:

RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?yourdomain.com [NC] RewriteRule \.(jpg|jpeg|png|gif)$ - [F,NC,L]

WordPress Plugins

There are plenty of plugins to prevent hotlinking if you use WordPress. Plugins such as All In One WP Security & Firewall and Wordfence Security provide special features for blocking hotlinking and protecting your media files.

How to Prevent Image Hotlinking

CDNs

Using a CDN can also combat the consequences of hotlinking. A CDN takes your content and distributes it among many different servers located across the planet, lessening the pressure on your main server. Many CDNs also include hotlink protection features.

Watermarking

Adding watermarks to your images can deter hotlinking. If someone does hotlink, the watermark will always attribute the image to its original source.

Conclusion

Hotlinking can lead to severe consequences for website owners. Your server costs can spiral out of control, or you could end up in hot water legally and lose all control over your content. Knowing what hotlinking is and how you can protect your site against it will help preserve your resources while providing a better user experience. Whether you use Cloudflare hotlink protection, WordPress plugins, or other methods, doing something to prevent your images from being used by others is necessary for a happy website life.

Abiding by these rules can help you better safeguard your site and improve its performance while protecting it from the adverse repercussions of hotlinking. For more tips and insight on improving site performance, check out How Insight for compressive hotlinking guides.


Post a Comment

0Comments

Post a Comment (0)