How to remove "Category:" from category archives?

Hi there,

I would like to have only the name of the category as Headline, without the proceeding "Category: "

I thought changing the ‘Category: %s’ to ‘’ in template_tags would do the trick, but no luck. What am I doing wrong?

Thanks in Advance!

Hello @stuermchen,

Please try to do the following, I will use “hats” as an example category, but please use your own category names.

  1. Go to your public_html/wp-content/themes/sydney folder (you can access it via cPanel or SFTP), copy archive.php file and rename it to category-hats.php.

  2. Open category-hats.php file with a text editor, find the following code:

<header class="page-header">
	<?php
		the_archive_title( '<h3 class="archive-title">', '</h3>' );
		the_archive_description( '<div class="taxonomy-description">', '</div>' );
	?>
</header><!-- .page-header -->

…replace it with this code:

<header class="page-header">
	<h3 class="archive-title">Hats</h3>
	<?php
		the_archive_description( '<div class="taxonomy-description">', '</div>' );
	?>
</header><!-- .page-header -->

…and save the file.

  1. Repeat the steps above to create .php templates for all your categories.

  2. Enjoy! :slight_smile:

Please feel free to ask any other questions that you might have.

Kind Regards, Roman.

Thank you, it worked! I just hope we won’t have too many categories. :slight_smile:

You are welcome @stuermchen! :slight_smile:

Kind Regards, Roman.