Lockdown Admin Backend to your IP

smartsovereign
13 Feb 2024

This code allows you to lock down your Wordperss Admin Backend so you can only see it from your current IP address.

Open Your File Manager in your cpanel

Navigate to the wp-admin folder
home > yoursite> public_html > wp-admin

Create a file called
.htaccess
(it must have a (.) DOT) this is a hidden security file.

Edit it and add the following code

Order Deny,Allow
Deny from all
Allow from 127.0.0.1 
112.123.2.244 (YOUR IP ADDRESS GOES HERE)



WARNING: Make sure that you can always access the admin area through your cpanel and update the IP address if needed.

Implications:

Was this article helpful?

Tags

Categories

Never miss new post again

Subscribe and get list of new posts in your inbox

Click to Copy