I'm hoping that you are my saviours. There seem be lots of people with this problem on the forums, but no clear answer. Here's my predicament:-

I've just put together a new Wordpress site on new hosting and it works a treat. I'm over the moon at how cool it is. However, on our previous (non Wordpress) hosting we had a little ordering system for our customers that sat in a folder in the route, away from the main. It has it's own index.php and could be reached by going to www.domain.com/ericsinfo

I brought the folder into the new hosting and positioned in the root just like before, however when I go to www.domain.com/ericsinfo I get a 404 error within Wordpress. Even if I type www.domain.com/ericsinfo/index.php, still a Wordpress 404.

I've read that I should edit the .htaccess file, but my template doesn't seem to have one and I don't really want to create one using other peoples recommended code unless I break something.

I can see that Wordpress taking over the 404 process is quite cool and don't want it to disappear entirely. I just want to be able to use the ordering system like we were previously able to.

I'll be eternally grateful for your help!



The problem your having is because of the way the WordPress rewrite system works. The WordPress .htaccess sends all requests (that dont actually exist except index.php) through the index.php file in the WordPress root directory. If any request is made for a file named index.php it will also get sent through the root WordPress index.php.

A simple solution would be to rename the index.php file in /ericsinfo to default.php. Depending on your hosting setup it might work by just doing that. If it doesn't you can add a 301 redirect to your .htaccess that points www.domain.com/ericsinfo to www.domain.com/ericsinfo/default.php

Redirect 301 /ericsinfo http://domain.com/ericsinfo/default.php

The .htaccess file will be located in your public_html or root public web directory.


you have to make it as a theme with a style.css in wp-content/themes folder then active the theme. Otherwise wordpress won't find it.



Please add this line at begin of your sub-directory htaccess file.

ErrorDocument 401 default

  • 1
    Please edit your answer, and add an explanation: why could that solve the problem? – fuxia Apr 18 '19 at 13:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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