Please read the question carefully before marking as duplicate.
We all know, that using in .htaccess:
.htaccess
RewriteCond %{REQUEST_FIL
how can I redirect in .htaccess all urls that contain index.php to to the same url without index.php?
Add this to your .htaccess
RewriteCond %{THE_REQUEST} ^[A-Z]{3,}\s(.*)/index\.php [NC] RewriteRule ^ %1 [R=301,L]