How to Enable Hotlink Protection in DirectAdmin

Hotlink protection helps prevent other websites from directly using your images, files, or media content without permission.

This guide explains how to enable hotlink protection in DirectAdmin.


What Is Hotlinking?

Hotlinking happens when another website displays files directly from your hosting account instead of uploading the files to their own server.

Examples include:

  • images
  • videos
  • downloadable files
  • media content

This can:

  • increase bandwidth usage
  • slow your website
  • use server resources unnecessarily

Before You Start

Before enabling hotlink protection, make sure:

  • You can log into DirectAdmin
  • Your website is active
  • Your images and media files are working normally

If you have not logged in yet, please see:

  • How to Log Into DirectAdmin

How to Enable Hotlink Protection

Step 1 — Log Into DirectAdmin

Open your browser and visit:  https://cp.yourdomain.co.za   (Replace yourdomain.co.za with your own domain name)

Enter your hosting username and password.


Step 2 — Open Hotlink Protection

From the DirectAdmin dashboard:

Click:  Account Manager 

Then click:  Hotlink Protection


Step 3 — Enable Hotlink Protection

Enable hotlink protection for your domain by doing the following..

Enter the first domain name that you want to protect

Click:  Add 

Click: Enable Hotlinks Protection


Step 4 — Select File Types to Protect

Common protected file types include:

 
jpg
jpeg
png
gif
webp
mp4
pdf
zip
 

These are the most commonly hotlinked file types.


Step 5 — Allow Approved Websites

You may allow certain trusted websites to access your files.

Click: Add my domains.

Examples:

  • your own domain
  • subdomains
  • CDN services

Step 6 — Save the Settings

Click: Save

Hotlink protection is now active.


How Hotlink Protection Works

After enabling protection:

  • approved websites can display your files normally
  • unauthorized websites may display broken images or access denied messages

This helps protect your hosting resources.


Common Uses for Hotlink Protection

Protect Website Images

Prevent other websites from displaying your images directly.


Protect Download Files

Reduce unauthorized linking to:

  • ZIP files
  • PDFs
  • downloads

Reduce Bandwidth Usage

Hotlink protection helps reduce unnecessary server traffic caused by external websites.


Important Notes

Search Engines Usually Still Work

Properly configured hotlink protection should still allow:

  • Google indexing
  • image previews
  • normal website visitors

CDN Services May Need Whitelisting

If you use:

  • Cloudflare
  • CDN services
  • external image optimization services

you may need to allow those domains.


Overly Strict Settings May Break Images

Incorrect configuration may prevent:

  • your own website images
  • themes
  • plugins

from loading correctly.


Troubleshooting

Images No Longer Display

Check:

  • allowed domains
  • file type settings
  • website configuration

Website Theme Looks Broken

Some themes or plugins may load images from:

  • subdomains
  • CDN services
  • external URLs

Whitelist trusted domains if needed.


Protection Not Working

Possible causes include:

  • browser cache
  • CDN caching
  • incorrect file types
  • unsupported configuration

Search Engines Cannot Index Images

Review:

  • allowed referrers
  • protection rules
  • CDN settings

to avoid blocking legitimate traffic.


Helpful Tips

Protect Large Media Files

Protecting:

  • videos
  • downloads
  • high-resolution images

can significantly reduce bandwidth usage.


Test Your Website After Enabling Protection

Always test:

  • homepage
  • galleries
  • product images
  • downloads

after enabling hotlink protection.


Keep Protection Settings Simple

Avoid unnecessary complexity where possible.


Security Tips

  • Protect valuable media files
  • Monitor bandwidth usage
  • Use CDN services carefully
  • Keep website software updated
  • Review protection settings regularly
  • directadmin ssl management, hotlink protection, website security
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How to Change Your DirectAdmin Password

Changing your DirectAdmin password regularly helps improve the security of your hosting account...

How to Check If Your SSL Certificate Is Working

After enabling an SSL certificate, you should check that your website loads securely using HTTPS....

How to Enable a Free SSL Certificate Using Let’s Encrypt in DirectAdmin

SSL certificates help secure your website and protect information sent between your website and...

How to Force HTTPS Redirects in DirectAdmin

After installing an SSL certificate, visitors may still be able to access your website using the...

How to Password Protect a Directory in DirectAdmin

DirectAdmin allows you to protect folders on your website with a username and password. This is...