WordPress source code

Show the current WordPress template file

When developing custom WordPress themes it is sometimes useful to be able to see at a glance which theme template file is being loaded for each page.

To show the path of the template file that is currently being loaded add the following snippet to your functions.php file:

Then ensure you are logged in as an administrator and the path to the current template will show at the bottom of your website. Please see the example below.

Template path

Useful links:

If you would like to discuss this article or have any other queries regarding custom WordPress themes please contact me.


Photo by Ilya Pavlov on Unsplash