Skip to content

HomeBlog › Enabling Hotlink Protection from cPanel

Enabling Hotlink Protection from cPanel

17 July 2025 · · cPanel

Enabling Hotlink Protection from cPanel
Enabling Hotlink Protection from cPanel. Hotlinking occurs when other websites directly use links to media files (images, videos, documents) hosted on your server, without downloading or hosting them locally. This behavior consumes your server resources (bandwidth) and can lead to high costs or decreased website performance. The Hotlink Protection function in cPanel prevents other websites from displaying your media files through direct links. Thus, only authorized domains (normally, your main domain and related subdomains) can load and display those files.
  1. Log in to cPanel
  2. Navigate to the Security section
  3. Click on Hotlink Protection
In the configuration interface you will see several options:
  • URLs to allow access: here are listed the domains that can access the files (usually the main domain and subdomains)
  • Block direct access for these extensions: you can specify the protected file extensions (e.g.: .jpg, .png, .mp4)
  • Redirect the request to this URL: optionally, you can send users to a custom page when they try to access files illegally
After configuring the options, press the Enable button to activate protection.

What types of files can be protected?

It is recommended to protect the following frequently used media file types:
  • .jpg, .jpeg, .png, .gif: images
  • .mp4, .avi, .webm: video files
  • .pdf, .docx: documents

Testing the protection function

To verify if the protection works:
  • Open an incognito window and try to load an image directly from the browser, using the file's URL address
  • Try to insert a protected file into an external page
  • Check if the file doesn't load outside the authorized domain
If you want to allow access to other domains or completely disable this function:
  1. Return to the Hotlink Protection section in cPanel
  2. Press Disable
Make sure that disabling is necessary, as this action removes protection for all media files. Enabling Hotlink Protection in cPanel is a simple and efficient measure to protect your digital resources. By preventing abusive use of media files hosted on your server, you ensure better website performance, reduce bandwidth costs and maintain control over your visual content.

How this article was made

Author
Published
17 July 2025
Last updated
18 September 2026
Sources

We work by our publishing principles, corrections policy, ethics policy.

Related articles