Responsive image

Call Us Today! 305 434 4698

Email :

Banner Image2
Recent Articles
Search Article
Article Category
How to create WordPress .htaccess file?
Friday, May 10, 2013    5:49 am

WordPress .htaccess file is an important file for taking security measures. Wp.htaccess file can be used to set-up various security settings. Using this, you can protect your blog from spammers; add rules for redirection, block bots and many more.

If you don’t know what .htaccess file is and how to create it, then today you can learn it in very easy steps and method. First of all let us learn what this file is and then move ahead.

About .htaccess file

The .htaccess file is an abbreviation for Hypertext Access. It is a configuration file used by Apache-based servers. Whenever you install WordPress, .htaccess file comes by default in maximum cases and remains at the root of your WordPress installation in hidden mode. If .htaccess file is not present, then you have to create it manually. Below is the default code for your Wp.htaccess file.

# BEGIN WordPress
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

# END WordPress

Steps to create .htaccess file

As we told, .htaccess file is present in most WordPress websites, click on option menu, then select force showing hidden files.

If the file does not exist, then you have to create it manually. For this, create a blank .htaccess file using notepad. After this, open your notepad and save it. Name this file as htaccess.txt. Ensure that it is not .htaccess.txt. In case, you are using Windows XP, you will not be able to name a file due to OS. But keep your calm; as you can rename it after it is uploaded on server.


Next step is to add content in your file. After saving htaccess.txt, you can edit the file and utilize it for managing your site without depending on PHP or JavaScript code. After creating it, you can upload it on your web server through ftp and rename file to .htaccess. Change the permissions of file to 644 to secure it from hackers. But, if you are modifying permalink and WordPress is not able to access your .htaccess file, you can change the permissions to 777 and update it.  However, make sure that you modify its permissions to 644, afterwards.

If you get 403 errors while posting or editing pages, then you can add “SecFilterInheritance Off” to the .htaccess file.  

By: admin

[Go Back]