fb-pixel
Logo Supporthost
Log in

Hotlink protection

November 30, 2021 / Published in:  from Ivan Messina
No comments

If you run a website, you may have heard of hotlinking before. It is usually considered bad practice because it can be detrimental to a website.

In this short tutorial, I will explain what hotlink protection is and how to enable it on your website.

What is hotlink protection and what is it for

Hotlinking is known as the act of stealing a website’s bandwidth by connecting directly to its resources, such as images or videos.

This practice can have several drawbacks, not only in terms of your website’s performance but also in terms of the traffic it can generate.

It may happen that other users, by directly implementing your images on their websites, can rank themselves better on Google Images, stealing the traffic you have been striving to create for a long time.

When a website embeds your resources directly, it connects to your website by leveraging your bandwidth to show these resources to its visitors.

Hotlink protection prevents other websites from linking directly to files, images, or videos on your website, solving these problems.

How to activate hotlink protection

There are several ways to enable hotlink protection. The easiest way is to enable it through cPanel.

After logging in to cPanel, you have to scroll down the page and select the item “Hotlink Protection“.

Cpanel Security Hotlink Protection

From this screen, you can configure all the tool’s settings.

To enable hotlink protection, simply click on the blue “Enable” button.

Enable Hotlink Protection

If the operation was successful, you will see a success message.

Configure hotlink protection

Still, from the same page, you can define some settings that will allow you to customize the hotlink protection.

For example, you can allow hotlinking from certain websites. To do this, enter their URL in the “URLs to allow access” field, as displayed in the below image.

Configure Hotlink Protection Url

It will allow all the websites you have specified to embed your resources directly.

You can also define the various file formats to which you want to deny access. You will simply have to write the various file extensions in the appropriate field, separating them with a comma.

Configure Hotlink Protection Extensions

By checking the “Allow direct requests” box, you will allow anyone to be able to view your resources only in the case of direct access (such as typing the URL of the resource in the search bar of the browser).

Configure Hotlink Protection Direct Requests

You can also decide to create a custom page on your website, which will be shown whenever someone tries to access your resources.

After you have created the page on your website, just enter the URL of the page in the “Redirect the request to the following URL” field.

Redirect Request Hotlink Protection

After performing all the changes, you will need to click on the “Submit” button to apply the changes.

Configure Hotlink Protection Submit

Disable hotlink protection

If you want to disable hotlink protection, first, you need to make sure it is enabled.

In case the protection is enabled, you will see the “Disable” button.

Disable Hotlink Protection

After clicking on the “Disable” button, a success message will be displayed confirming that the operation was successful.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

crossmenu