Title: Error page template (404.php) not loading
Last modified: August 19, 2016

---

# Error page template (404.php) not loading

 *  [andybryant](https://wordpress.org/support/users/andybryant/)
 * (@andybryant)
 * [17 years, 12 months ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/)
 * When invoking a 404 Page Not Found I’m getting either a blank screen or a partially
   loaded page (i.e. fragments of code from the template 404.php).
 * I’ve got my WordPress blog in a subfolder of my domain. I’m using the htaccess
   file to set errorDocument at the root of the site, and this works fine when the
   requested file is outside of the blog. For example:
 * [http://www.lessfussdesign.com/nopage](http://www.lessfussdesign.com/nopage)
 * But any URLs within the blog and I get this:
 * [http://www.lessfussdesign.com/blog/nopage](http://www.lessfussdesign.com/blog/nopage)
 * I’ve tried switching to the default or classic theme (thinking it might be something
   I’ve done in my theme) but I get the same problem. It’s only for 404 errors, 
   so for example an Access forbidden is fine, even when the URL is in the blog:
 * [http://www.lessfussdesign.com/blog/wp-content/themes/](http://www.lessfussdesign.com/blog/wp-content/themes/)
 * I’ve got a 404.php template in my theme folder, but clearly this isn’t being 
   called. Has anyone come across a similar problem, or can think of something (
   probably obvious!) that I’m not doing/should be doing?

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Thread Starter [andybryant](https://wordpress.org/support/users/andybryant/)
 * (@andybryant)
 * [17 years, 12 months ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796157)
 * I found another post in this forum from someone who had exactly the same issue,
   but unfortunately nobody was able to help him – all the replies completely missed
   the point.
 * It’s the .htaccess file that causes the problem. Delete it and disable permalinks
   in WP and you can use your own error handling instead of the WP default.
 * I’m now using ‘almost pretty’ permalinks as they don’t require .htaccess, so 
   all the example 404 links in the above post will now lead to my proper 404 page.
 * I’m leaving this open because it isn’t resolved. If anyone else gets anything
   similar please post a response here.
 *  [digg](https://wordpress.org/support/users/digg/)
 * (@digg)
 * [17 years, 8 months ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796230)
 * I’m getting the same exact problem. I’ve literally been reading for over 10 hours
   and have yet to find a solution.
 * If I don’t use pretty permalinks (and consequently no .htaccess file) the 404
   error page WITHIN the theme kicks in for a non-existing link.
 * If I use pretty permalinks, post links work, but links like /about, or /contact
   do not and the user is sent to a SERVER based (Apache) 404 error page.
 *  [organicjar](https://wordpress.org/support/users/organicjar/)
 * (@organicjar)
 * [17 years, 8 months ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796232)
 * Hey, did you ever figure the RSS Feed problem out?
 *  [whooami](https://wordpress.org/support/users/whooami/)
 * (@whooami)
 * [17 years, 8 months ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796233)
 * organicjar, why dont you start your own thread, and ask your own question?
 *  [codinggeek](https://wordpress.org/support/users/codinggeek/)
 * (@codinggeek)
 * [17 years ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796295)
 * Ok. I know this is not solution to this problem, but I’m posting this as this
   thread is displaying on google search result for 404 error problems.
    If you 
   are using only pages, probably your 404.php will not work and your page.php doesn’t
   have code for “no posts”. So copy the else part of having posts section and paste
   it in your page.php

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Error page template (404.php) not loading’ is closed to new replies.

## Tags

 * [error pages](https://wordpress.org/support/topic-tag/error-pages/)
 * [htaccess](https://wordpress.org/support/topic-tag/htaccess/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 5 replies
 * 5 participants
 * Last reply from: [codinggeek](https://wordpress.org/support/users/codinggeek/)
 * Last activity: [17 years ago](https://wordpress.org/support/topic/error-page-template-404php-not-loading/#post-796295)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
