How To Remove Index.php From Url In WordPress (Step by Step)
Today, I am focusing on a common issue for WordPress users: removing index.php
from your website’s URLs.
This change can significantly enhance your site’s user experience and improve its SEO friendliness.
The Challenge
While working on my clients projects, I noticed that my URLs included index.php
.
This issue was apparent in all sections of their sites, including the ‘Contact’ page.
Instead of displaying a clean URL like domain.com/contact
, it showed domain.com/index.php/contact
, which is not ideal for user experience or SEO.
Remove index.php from URL Step-by-Step Guide:
Step 1: Accessing WordPress Dashboard
Start by logging into your WordPress dashboard. This is your control panel, where you can make all kinds of changes to your site.
Step 2: Navigating to Permalinks Settings
In the dashboard, look to the left-hand menu. Scroll down until you find the ‘Settings‘ option. Hover over it and click on ‘Permalinks‘.
Step 3: Choosing the Right Permalink Structure
You’ll notice the current URL structure that includes .php
.
To remove this, simply alter the settings. Choosing ‘Post name’ as your permalink structure is generally a good practice, as it keeps URLs simple and SEO-friendly.
However, you’re free to select any structure that suits your needs.
Step 4: Saving the Changes
After selecting ‘Post name’, scroll down and click on ‘Save Changes’. This step is crucial to ensure your changes are applied.
Step 5: Verifying the Changes
To check if the removal was successful, go to ‘Pages’ and view all pages. Open any page, like the ‘Contact’ page, and observe the URL. The index.php
should now be removed, making your URLs cleaner and more professional-looking.
Conclusion
Removing index.php
from your WordPress URLs is a simple yet effective way to make your site more accessible and search-engine friendly. It’s a small change that can have a significant impact on your website’s performance and user experience.