General Topics

Access htaccess File WordPress Step By Step

Access htaccess File WordPress Step By Step

WordPress is a self-hosted software which gives freedom to use it with a powerful grip on your website. Now I am going to tell you about the way to access htaccess file WordPress. You know htaccess file is the most important file of the WordPress. Because in which you can create rules regarding site’s security. You can block bots, create 301 redirects and secure your site from spammers etc.

Either, many WordPress site’s owners don’t have an idea about it in depth. I will tell you some codes also for securing your website from hackers. Now let’s start to proceed this:

Knowledge About htaccess file WordPress?

This is a file which is not only linked with WordPress. Most hosting providers offer htaccess file feature. While installation of WordPress htaccess file also available but often not showing. So after check the option to show dot files the hidden files come in front of your eyes.

But after check the option to show hidden files. If you have failed to see then just create a new file with the name of .htaccess.

File Manager CPanel

After it, just save settings by accessing WordPress dashboard. Settings » Permalinks. If a new file has created in the root directory then better otherwise just create a new file and paste the below code.

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

# END WordPress

There are two methods to access htaccess file. The first one is CPanel and second is edit it via WordPress plugin. Now here a question arises which WordPress plugin? Yes! that the Yoast SEO. Due to this plugin, you are going to higher rank your site and access robots.txt and htaccess file easily.

After installation of this plugin, you don’t need to login CPanel. However, I am sharing here both methods to access this file.

Let’s see if you want to access this file via CPanel then how to?

Access htaccess File Using CPanel In 2 Minutes

Let’s see how to access htaccess file using CPanel in just 2 minutes.

1| Login CPanel

First Login to the CPanel.

2| Open File Manager

After logging in find File Manager and click on it. Now check Show hidden files.

File Manager CPanel

3| Open Public HTML Folder

Now open the public_html folder by click on any one side.

Public HTML folder

4| Search File

You have to access the htaccess file.

.htaccess file location CPanel

5| Edit File

Edit your file like shown as under screenshot.

Edit File in CPanel

Access htaccess File Via Yoast SEO Plugin

Above I have told how to access htaccess file using CPanel. Now the turn how to access this file via WordPress plugin Yoast SEO.

1| Login Dashboard

First login WordPress admin area. In left pane search Yoast SEO tab and click on it. It will expand now click on Tools.

Yoast SEO Tools

2| Open Tools

The new interface will open like shown as under pic. Now click on File editor. Just scroll down you will get here.

Yoast SEO File Editor


That’s the method to access the htaccess file. If you have this file and want to modify this then take backup of this file. Because due to wrong insertion of code you will down your website. In the case of any difficulty, you can leave a comment in the comment section. If you like this then don’t forget to follow us on Twitter. Lastly, I have some suggestions for you which will help you to rank higher on Google. Just click on the below link and enjoy these ones.

Supporting Articles

  1. How To Create?
  2. SEO Strategy 2017: Experienced Way Which Create 502% Organic Visits
  3. Would You Like To Know About Dofollow Backlink With Bonus Tip

Tagged With
Show More

Global Blurb Team

"Global Blurb since 2015" Global Blurb providing information about SEO, Beauty, Health & Fitness, Interior designing, Fashion and ways of earning online without investing a penny. The blog designed to share ideas about different topics.

Want to contribute

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Back to top button