Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

settler's avatar

URL with Index.php

My site is 'apparelshopusa.com', my question is that, i have not defined in my route anywhere 'index.php' so why my site is running on this url -> 'https://www.apparelshopusa.com/index.php', it has also been crawled by google. Please help.

0 likes
3 replies
settler's avatar

Thank you ring4ik, i'm going through your link for the solution, and let you know.

settler's avatar

Through your given urls my one problem is solved. https://www.apparelshopusa.com/index.php/20-camis -> (redirects to) https://www.apparelshopusa.com/20-camis by the help of below code Code in .htaccess RewriteCond %{THE_REQUEST} ^./index.php RewriteRule ^index.php/(.)$ /$1 [R=301,L]

Remaining Issue: But the below url is still creating problem, not redirecting to home page. https://www.apparelshopusa.com/index.php ->(should be) -> https://www.apparelshopusa.com

Please or to participate in this conversation.