Skip to content
Your Hosting Ad Goes Here KBAssets

How to Configure HotLink Protection in cPanel

HotLink Protection helps prevent other websites from directly linking to your website’s files, such as images, videos, or other media. This helps you save bandwidth and protect your resources from being used without permission.

Step 1: Log in to cPanel

  • Begin by logging into your cPanel account.

Step 2: Access the HotLink Protection Interface

  • Scroll down to the Security section.
  • Click on HotLink Protection.

Step 3: Configure URLs to Allow Access

  • In the URLs to allow access field, enter the domains that are allowed to link directly to your files. By default, your domain will already be listed.
  • Add any additional trusted domains that should have access.

Step 4: Block Direct Requests

  • Ensure that the box labeled “Allow direct requests (requests made without referring URLs)” is unchecked to block others from directly accessing your files without proper referral.

Step 5: Specify File Types to Protect

  • In the Block direct access for the following extensions (comma-separated) field, specify the file types you want to protect, such as .jpg, .png, .mp4, etc. These files will be blocked from hotlinking.

Step 6: Redirect Blocked Requests (Optional)

  • If you want users to be redirected to a specific page when they attempt to hotlink your files, enter the URL in the Redirect the request to this URL field.

Step 7: Enable HotLink Protection

  • Click Enable to activate HotLink Protection for your site.

Step 8: Confirmation

  • You will receive a confirmation message indicating that HotLink Protection has been enabled.
Was this article helpful?
YesNo
Back To Top