Home WebServer PanelcPanel How to use Hotlink Protection on aaPanel to prevent image embedding

How to use Hotlink Protection on aaPanel to prevent image embedding

by Thạch Phạm
Published: Last Updated on

In this article, AZDIGI will show you to use hotlink protection to prevent embedding your images on other websites.

Refer to the high-speed hosting service here.

I. Should we prevent embedding images on the web?

I think it should because imagine your website is in the field of real estate or comics and there are a lot of images on the website that are directly linked to other people’s websites.

Then the first thing you will notice is that your website must run heavier because when users visit those other websites, your hosting will also have to serve the images on that person’s website.

And you get almost nothing out of it. Instead, the beneficiary is the person who embeds your image on their website, helping their hosting package run smoothly and with less bandwidth.

So in this article, I will help you prevent that with the hotlink protection feature on aaPanel to help prevent embedding images on other websites.

II. Prevent image embedding with hotlink protection on aaPanel

To prevent image embedding with hotlink protection on cPanel, we need to follow these 3 steps.

Step 1: Access to cPanel interface

To access to cPanel, please refer to the following tutorial:

Step 2: Find and access the Hotlink Protection feature

On cPanel, you enter the Hotlink keyword search bar to find this feature.

prevent image embedding, hotlink-protection-cPanel

At the interface of this feature, you will see that this feature is turned off by default (1) as shown below: You can refer to the interface of this feature below:

prevent image embedding, hotlink-protection-cPanel

I will explain the fields in this interface:

  1. Enable: Enable Hotlink Protection feature.
  2. URLs to allow access: – enter the URL you want to permit linking to your files. By default, this will automatically get the domains on your hosting package.
  3. Block direct access for the following extensions (comma-separated): – you can enter the file extension that you want to block direct embedding.
  4. Allow direct requests – select this option if you want to allow direct access from the browser (for example, when opened with the path http://yourdomain.com/image.png).
  5. Redirect the request to the following URL: – If you want you can redirect the blocked request to a certain URL, for example, one of your domain’s pages. You will need a valid URL of the form http://yourdomain.com/index.php.
  6. Click Submit to save all changes.

That’s it, now your files on hosting are protected from being used by unwanted websites.

Note: If you find that files such as images or videos don’t work after enabling HotLink protection, make sure your domain has been added to the list of URLs to allow access (2).

Now, you can check if the other websites have been blocked from embedding images.

III. Summary

In this tutorial, AZDIGI showed you how to enable HotLink Protection on cPanel on your website. It will help you block image embedding and help save your site’s bandwidth from being misused by others without your permission.

Wishing you success!

See more useful cPanel articles at the following link:

If you need assistance, you can contact support in the ways below:

Đánh giá

Tham gia nhóm hỗ trợ Server - Hosting

Tham gia nhóm Hỗ trợ Server - Hosting & WordPress để cùng nhau hỏi đáp và hỗ trợ các vấn đề về WordPress, tối ưu máy chủ/server.

Tham gia ngay

Bài viết cùng chuyên mục

AZDIGI – Không chỉ là đơn vị hàng đầu trong lĩnh vực Web Hosting và Máy chủ, chúng tôi mong muốn mang lại những kiến thức bổ ích nhất và luôn cập nhật thường xuyên cho cộng đồng người đam mê thiết kế website, công nghệ,…

Vui lòng không sao chép nội dung nếu chưa xin phép. Designed and Developed by PenciDesign