Can a tag and a category have the same name in WordPress?
Yes. WordPress treats categories and tags as separate taxonomies, so each can have a term called "Espresso" with the slug espresso. They get different addresses, /category/espresso/ and /tag/espresso/. It works technically, but you now have two archive pages on one topic competing with each other.
What core allows and what it blocks
Term names and slugs only have to be unique within their own taxonomy and level:
| Situation | Allowed? | Result |
|---|---|---|
| Category "Espresso" and tag "Espresso" | Yes | Both keep the slug espresso |
| Two tags named "Espresso" | No | "A term with the name provided already exists in this taxonomy." |
| Two categories named "Espresso" at the same level | No | "A term with the name provided already exists with this parent." |
| Two categories named "Guides" under different parents | Yes | The second slug gets the parent's slug added, such as guides-brewing |
| A custom taxonomy term with the same name as a category | Yes | Separate taxonomy, same slug |
The two terms are completely independent. They have different IDs, different post counts, different descriptions, and assigning a post to one does nothing to the other.
There is one case where identical slugs collide, and it has nothing to do with taxonomies sharing names. If you remove the category base so categories live at /espresso/ instead of /category/espresso/, a category can then clash with a page or post that has the same slug.
Why the pair is a problem
Each term has an archive. If you tag every post in the Espresso category with "espresso", the two archives list exactly the same posts in the same order. They differ only in the heading and the address:
/category/espresso/ → Category: Espresso → posts A, B, C, D
/tag/espresso/ → Tag: Espresso → posts A, B, C, D
That is duplicate content in the plain sense: two URLs, one set of content. Google will usually pick one to show and ignore the other, and it may not pick the one you would. Meanwhile internal links are split between the two, since every post links to both from its category and tag lists.
Even when the lists are not identical, two pages aimed at the query "espresso" on the same site is a small case of keyword cannibalization. Neither page gains from the other existing.
Core will not sort this out for you. It prints no canonical tag on archives, so nothing tells search engines which of the two is preferred.
Which one to keep
Decide by what the term is:
- It is a section of the site that most posts on the subject belong to. Keep the category. Remove the tag.
- It is a detail that cuts across sections, such as a brand or technique mentioned in posts filed under several categories. Keep the tag, and do not make a category for it.
A helpful test: if the tag would only ever appear on posts in the same-named category, it adds no information. A tag is useful when it groups posts that categories do not.
Removing the duplicate cleanly
- Confirm the overlap. Compare the post counts on Posts → Categories and Posts → Tags, then open both archives.
- Check which archive Google knows. Inspect both addresses in Search Console, and look for either in the performance report. Keep the one with traffic if the choice is otherwise even.
- Move any stragglers. If the tag has posts that are not in the category and belong there, add them with bulk edit before removing the tag.
- Redirect the loser to the keeper with a 301:
/tag/espresso/to/category/espresso/. In Hydrogen SEO, add it in the Redirection Manager. Core has no redirect for removed terms. - Delete the duplicate term. Posts lose that tag and keep everything else.
- Stop it recurring. Agree a house rule that tags never repeat category names, and prune the tag box suggestions that authors click out of habit.
WordPress used to ship a Categories and Tags Converter under Tools → Import for turning one into the other. It is now a separate importer plugin; for a single pair, the manual steps above are quicker.
If you want to keep both
Sometimes both are in use in ways that are hard to untangle on a large site. Then make sure only one is indexed:
- Noindex the tag archive, or all tag archives if you do not curate tags. In Hydrogen SEO, the Robots screen sets this per taxonomy, and each term's own SEO settings sheet can override it.
- Or canonicalise the tag archive to the category archive, when the lists are effectively the same.
- Differentiate them with distinct titles, descriptions and intro text if both stay indexed, so they at least target different wording.
The guide to noindexing tag and category archives covers the taxonomy-wide decision.
Common questions
Will WordPress add -2 to the tag slug if a category has the same slug?
No. Slugs only need to be unique within one taxonomy, so the category and the tag can both be `espresso`.
Is having the same tag and category a Google penalty risk?
No penalty. The cost is two near-identical archives, where Google indexes one and your internal links are divided between them.
Can I convert a tag into a category?
Yes, with the Categories and Tags Converter importer plugin, or by adding the category to the tagged posts in bulk and then deleting the tag.