Magento by default uses index.php for routing to urls. It is because some time you are on shared hosting and your apache is not configured with url rewrites = on or even on dedicated server you don’t have configured apache to work with url rewrites.
To remove “index.php” from magento urls you need to turn on the url rewrites.
Dedicated Hosting
It is simple in dedicated hosting
Edit httpd.conf (apache configuration file) and un-comment following line by removing “;” or “#” from beginning of line.
for example
change
#LoadModule rewrite_module modules/mod_rewrite.so
to
LoadModule rewrite_module modules/mod_rewrite.so
Save the file and restart apache.
Shared Hosting
In shared hosting that is normally on, but if that is off then you need to contact your hosting provider to turn it on.
Magento Configuration
After making sure url rewrites are on, go to Magento backend > configuration > General > web
Look for “Search Engines Optimization” section
Look for “Use Web Server Rewrites” and select “Yes” from dropdown, Save the config and refresh the front page of your website, you will see index.php is removed from urls.
Enjoy 🙂
Excellent blog! Do you have any hints for aspiring writers?
I’m planning to start my own blog soon but I’m a little lost on everything.
Would you propose starting with a free platform like
Wordpress or go for a paid option? There are so many options out there that I’m totally confused ..
Any suggestions? Appreciate it!
I think it would be good to start on your own domain, its always a good option as SEO is concerned