Title: wordpress not finding single.php ?
Last modified: August 18, 2016

---

# wordpress not finding single.php ?

 *  [shownomercy](https://wordpress.org/support/users/shownomercy/)
 * (@shownomercy)
 * [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/)
 * For a theme I am working on, wordpress is not finding the single.php file. This
   is abundantly clear as the index is quite altered, and all the single pages are
   reverting to index.php.
 * Anyone have any guesses as to why it’s not finding my single.php, perhaps grave
   syntax errors that would cause it to revert to index.php? I do want to have to
   make my homepage a page with template for various reasons, but this is one workaround
   I have in mind…

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

 *  Moderator [Samuel Wood (Otto)](https://wordpress.org/support/users/otto42/)
 * (@otto42)
 * WordPress.org Admin
 * [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/#post-663911)
 * Without more information, we don’t know. If the single.php is there in the template
   directory, and you’re hitting a single post page (is_single() returns true), 
   then it will use it. Simple as that, really.
 *  Thread Starter [shownomercy](https://wordpress.org/support/users/shownomercy/)
 * (@shownomercy)
 * [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/#post-663914)
 * Let me try again since I doubt anyone wants to read my hundreds lines of rough
   code..
 * I have a single.php file in the template directory.
 * And it is returning index.php for the single page IE when I click on a “permalink”.
 * (other template files such as page.php, archives.php, are working as indicated
   by the template hierarchy)
 * Has anyone had this problem before?
 *  Moderator [Samuel Wood (Otto)](https://wordpress.org/support/users/otto42/)
 * (@otto42)
 * WordPress.org Admin
 * [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/#post-663923)
 * 1. Check the permissions of single.php. Make sure it has the same permissions
   as the theme’s index.php. If WordPress can’t access it, then that’s the same 
   as if it’s not there.
 * 2. What is the value returned by `is_single()` on these problem pages? Try adding
   something to your index.php that looks like this:
 *     ```
       if (is_single()) echo "SINGLE PAGE DETECTED!";
       else echo "NOT A SINGLE PAGE!";
       ```
   
 * This will let you know whether WordPress thinks you are requesting a single page
   or not. If it thinks you’re not, then you need to find out why not.
 * 3. What is your custom permalink setting? Some permalink settings won’t work 
   because they are not specific enough.
 *  Thread Starter [shownomercy](https://wordpress.org/support/users/shownomercy/)
 * (@shownomercy)
 * [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/#post-663935)
 * duh thank you! Great tip for figuring out the matter.
 * As it turns out this is some permalink/.htaccess related issue, in case anyone
   has the problem in the future and doesn’t have any permission issues with their
   individual template files, or any typos in template files.

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

The topic ‘wordpress not finding single.php ?’ is closed to new replies.

## Tags

 * [single.php](https://wordpress.org/support/topic-tag/single-php/)
 * [template hierarchy](https://wordpress.org/support/topic-tag/template-hierarchy/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 4 replies
 * 2 participants
 * Last reply from: [shownomercy](https://wordpress.org/support/users/shownomercy/)
 * Last activity: [18 years, 5 months ago](https://wordpress.org/support/topic/wordpress-not-finding-singlephp/#post-663935)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
