The .htaccess file contains special instructions that directs your server on how to behave in certain scenarios. This file has a crucial effect on how your website functions.
WordPress sites and other CMS like Drupal and Joomla rely heavily on the .htaccess file to rewrite URLs and do some redirects.
There are times when you may need to find and edit this file. There are many ways to do it but the easiest way is to use the file manager in cPanel.
How To Find the .htacces File
1 Login to your cPanel. How to?
2 Find and click the File Manager icon under the Files section.
3 Find the .htaccess file in the list of files. You may need to scroll to find it.
4 If you don’t see .htaccess file on the File Manager page, make sure “Show Hidden Files (dotfiles)” is checked. See dialogue box below.
You can access this dialogue box by clicking “Settings” button found on the right topmost part of the file manager page.
If Show Hidden Files (dotfiles) is unchecked, checked it then click Save button. You should be able to see the hidden htaccess file.
Editing the .htacces File
1 Right click on the .htaccess file and click “Edit” from the popup menu.
Alternatively, select or highlight the .htaccess file then click “Edit” link on the top menu bar.
2 A popup box may appear asking you about encoding. Just click Edit to continue.
3 Edit the file as needed.
4 When done, click “Save Changes” button located in the upper right hand corner.
5 That’s it. Check your website to make sure your changes were successfully saved.