What's the file to edit the category template? (4 posts)

  1. hildergarn
    Posted 4 years ago #

    Hi. I want to know what's the file template I need to open to edit the category template? Maybe it's a silly question, but I tried to find the answer with no success.

    Thanks in advance!

  2. technodude95
    Posted 4 years ago #

    It's the 'archive.php' template.

    I would be wary of the below method because it requires you to not only assign individual php pages to categories (which in itself requires a set of requirements for making sure the new template is formatted correctly), but also actually create a new template versus just editing one.

    The way that wordpress generates category pages is using the 'archive.php' template. Edit that and it will edit the layout of the page when anyone clicks on any category.

  3. Tarsem Singh
    Posted 4 years ago #

    Hi hildergarn,
    it's Not a silly question :) .
    You can Create a page with name category.php.. for more information please visit . Category Templates

  4. Michael
    Forum Moderator
    Posted 4 years ago #

    working with this codex chapter, you shold be able to find which template is doing what:

    what's the file template I need to open to edit the category template?

    starting at the top of the list - if the template does not exist in your theme, look for the one further down:


    assuming that your theme does not have a category.php, but you wat to style category archives different from normal (date) archives, make a copy of archive.php and save it as category.php (you need to use ftp or the file management of your hoster for this) then edit it to your needs.

Topic Closed

This topic has been closed to new replies.

About this Topic