How to create htaccess file for WordPress

0

htaccess file is one of the most important files for your WordPress website, it can do tons of tasks. Lets create one.

how-to-create-htaccess-file

If you have a WordPress website then you need .htaccess file to do a lot of things for your website. WordPress delivers a CMS which gives you complete freedom to make changes to your website and to take care of many tasks you just have to use .htaccess file that can redirect, allow or block IP, making your website secure, SEO and many things.

What is a .htaccess file?

All the WordPress websites and apache servers use the .htaccess file. htaccess is short for Hypertext Access used by apache servers to control the functioning of the directory it’s in and subdirectory that are underneath it .Most of the time WordPress creates one at the time of installation, This can be found at the root directory, mostly this is hidden if you are using a ftp client then have the show hidden files enabled, but some time It’s not there then you have to create one.

How to create htaccess file for WordPress?

If you are a Windows user than before starting you have to make some changes to your folder and file properties of your desktop. Now at first you just have to go to your explorer and when the window opens you have to press that ALT key and you will see a title bar, in that there will be tools, when you click it then you will find folder options.

create-htaccess-file-folder options

When you click this then a new window will popup where you will see that there is a tab called view there you just have to click it and there you will see an option named hide extensions of known file types, just uncheck and save it.

create-htaccess-file-folder options-view

Now we can start with how to create htacces file. Now you will be able to see the extensions of the files that we will create.

Go to your notepad and create a file named htaccess.txt, make sure that you named it htaccess.txt not .htaccess.txt . After you save this it’s time to upload it to your server. You can use your file manager in cpanel or ftp, After you upload change the file name from htaccess.txt to .htaccess

Now you can edit and put the code that you like to in your .htaccess file directly from FTP or file manager.

Also read:

If you liked the post then please share it, and to ask a question or for starting a conversation use the comment section below.

You can follow us on twitter, facebook, Google+

Leave a Reply

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