If you are tired of removing your WordPress blog URL looking like this: http://www.yoursite.com/index.html, then this post is for you! We will show you how to remove the index.html or index.php from your WordPress URL to look more professional and modern.

Or you have migrated one server to another; there are very chances to add index.php or index.html in the URL.

Remove index.html php from WordPress URL – How do I?

Do not use the word “index” or “php” in your blog address, this will make it difficult for visitors to find your site on search engines. How can I change my blog’s URL so that visitors and search engines are able to locate my website?

Tutorials on How to do it?

Check “mod_rewrite” is Enabled on your server?

If you don’t have direct info from your hosting provider, you can try checking your hosting for this.

If it’s enabled, it should say “AllowOverride All” in the .htaccess file (or other Apache configuration files).

Edit your .htaccess file

Go to your server root directory and Check your .htaccess file

Add this line in the .htaccess file

Change YOUR-EXISTING-URL to your WordPress URL.

Save and reload the website, if it still does not work then contact your hosting provider for further assistance.

Set the permalink structure in WordPress

Go to Settings → Permalinks

Select Custom Structure and input %postname% into the text field. Click Save changes.

Click on save all settings and go to your WordPress blog URL, for example, How-to-remove-index.html from WordPress URL and it will redirect you automatically without index.HTML in the URL.

wordpress permalink structure

Video Tutorial: how do I remove index html PHP from WordPress URL?