Ok, so I have tried countless solutions and not one of them worked for me.

My problem is that every link in my Magento installation contains the infamous "index.php" string.

Now, if I click on one of these link I get a "no input file specified" error. But if I take the url and manually remove the "index.php" part, I get to the right page.

Example from my backend:

I want to get to my dashboard. If I click on the "dashboard" button, my browser gets redirected to: http://www.example.com/index.php/admin/dashboard/index/key/1871429d86978a097e7447672b3b12bw/ and I get a "no input file specified" error screen.

But if I take the url and edit this way: http://www.example.com/admin/dashboard/index/key/1871429d86978a097e7447672b3b12bw/ I get to the right dashboard page, as it should normally work.

Obviously, I want to remove the index.php part from my urls.

My .htaccess currently file reads as follows (and I tried every combination found on the internet for it, some of them gave me a 500 server error, so I know that url rewrites are enabled for my hosting):

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ / [L]

In my settings I have enabled url rewrites, secure urls for both backend and frontend and the secure and unsecure urls are correct ("www.example.com/").

Can anyone help me? Thanks.

  • Have you tried resetting cache, and running reindex for URL rewrites?
    – Dmytro
    Jan 14, 2015 at 9:59
  • Yes, my cache is disabled and my indexes have been rebuilt.
    – Giovanni
    Jan 14, 2015 at 15:29

1 Answer 1


After being in touch with my hosting support, they managed to solve my issue by modifying something in the cgi configuration.

I don't really know what they changed, but I think it's something like what is written on the step 2 of this guide.

I'll report it here, in case the page gets changed.

By default, the web server will want to run the Magento application using PHP4, which will not work. In order to point it to the new PHP5 CGI binary, you must modify the .htaccess file in the Magento top-level directory.
Using your FTP client, edit the file .htaccess in your top-level Magento directory.

The file is somewhat long so we won’t list it all here. But the first few lines at the top should look like this:

## uncomment these lines for CGI mode
## make sure to specify the correct cgi php binary file name
## it might be /cgi-bin/php-cgi

# Actions php5-cgi /cgi-bin/php5-cgi
# AddHandler php5-cgi .php
# php.flag cgi.fix_pathinfo on


First, remove the # symbol from the beginning of the last three lines listed in the excerpt above. This will enable the special CGI handler for your Magento site. Next, you’ll want to modify the path in the Action line to point to the location of the php5-cgi binary you uploaded in Step 1. This path should be relative to the web root of your site.

That’s it! You can now proceed with the rest of the Magento installation.
  • Done. Thank you.
    – Giovanni
    Jan 29, 2015 at 14:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.