WordPress how to hide wp-content using htaccess

Its’ very simple to hide all your wp-content files or wp-content directories using .htaccess

hide-wp-content-directory

What you need to do is to create .htaccess file using Notepad++ and input the below code. Put this inside your wp-content

[code]Options -Indexes[/code]

When someone tries to access your wp-content, they will get this error message

Forbidden
You don’t have permission to access /wp-content/uploads/ on this server.

I’ve zip this file into a folder, place the .htaccess file into your wp-content

Here you can download the zip file htaccessFile

Leave a Reply

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