When customizing a WordPress theme, figuring out which PHP file controls the current page layout can turn into frustrating guesswork. Digging through nested theme directories and child theme folders wastes valuable time. KO Show Current Template lets you show current template in WordPress admin bar with zero setup.
You can inspect active template hierarchy files and included template parts as you browse your live site. This tool is part of my collection of free WordPress plugins built to streamline everyday website building with clean, lightweight code.
- Version: 1.0.0
- Requires WP: 6.0+
- PHP: 7.4+
- Frontend Assets: 0 KB
- License: GPLv2
Why I Built KO Show Current Template
WordPress uses a complex template hierarchy system to choose which PHP file renders each page. Depending on custom post types, categories, taxonomies, and page slugs, your layout might load from single.php, page.php, archive.php, or a custom child theme template.
Switching back and forth between your code editor and browser trying to guess which template file is active slows down your design tweaks.
I built this micro-plugin to put that information right in front of you. It hooks directly into the WordPress template engine, catches the active file, and displays the exact template filename and all loaded sub-parts in your top toolbar.
How to Inspect Active Theme Template Files
Here is how this tool lets you show current template in WordPress frontend pages:
- Instant Admin Bar Node: Displays the active template filename right in your top admin toolbar as you browse pages.
- Relative File Paths: Hover over the admin bar node to see the exact relative path inside your parent or child theme folder.
- Included Template Parts: Lists all included PHP sub-templates loaded on the current page (like headers, footers, and content cards).
- Administrator-Only Access: Protected by permission checks so regular site visitors never see template filenames.
- Zero Frontend Script Weight: Operates entirely on server-side PHP filters with 0 KB of frontend JavaScript or CSS.
- 100% Free & Open Source: Released freely under the GPLv2 license with the full source code on GitHub.
How to Install and Use KO Show Current Template
Setting up template inspection takes less than two minutes:
- Download the ZIP: Grab the latest
ko-show-current-template.zipfile using the download button above. - Upload & Activate: Head into Plugins -> Add New Plugin -> Upload Plugin in your dashboard, select the zip file, and click Activate.
- Browse Your Live Site: Visit any frontend page while logged in as an admin to see the active template name displayed in your top toolbar.
Hover over the template node in your toolbar at any time to view full relative paths and included template parts.
Frequently Asked Questions About KO Show Current Template
Where does the active template name appear?
It appears directly in the top WordPress admin toolbar when you view any frontend page while logged in as an administrator.
Can regular visitors see my theme template filenames?
No. The plugin verifies administrator capabilities before rendering the toolbar node. Regular visitors and logged-out users never see template details.
Does this tool support child theme templates?
Yes. It automatically detects whether a file loads from your child theme or parent theme directory and shows the exact relative file path.
Can I use this plugin on client websites?
Yes. KO Show Current Template is licensed under GPLv2, which means you can install and use it freely on unlimited personal, business, or client websites.