---
title: "How to Search by Post Tag in WordPress?"
url: https://nexterwp.com/docs/search-by-post-tag-in-wordpress/
date: 2024-12-02
modified: 2026-09-27
lang: en
author: "Aditya Sharma"
description: "Tags describe a post more precisely than a category does. If your readers think in tags, give them a tag filter rather than a category one. The setup is identical..."
image: https://nexterwp.com/wp-content/uploads/2024/12/How-to-Search-by-Post-Tag-in-WordPress_-1024x519.jpg
word_count: 418
---

# How to Search by Post Tag in WordPress?

## Key Takeaways

- Nexter Blocks Search Bar block lets site owners search posts by tags in WordPress by setting Source to Taxonomy and Select Taxonomy to Tags.
- Search Bar block adds a dropdown beside the search bar, with Label and Placeholder fields for the select dropdown.
- AJAX Search toggle in the Extra Option tab enables tag-based searches so users can select a tag or directly search for blog posts with a specific tag.

Tags describe a post more precisely than a category does. If your readers think in tags, give them a tag filter rather than a category one.

The setup is identical to the category version — only the taxonomy changes.

*For every Search Bar setting in one place, see the [Search Bar guide](https://nexterwp.com/docs/add-a-search-bar-in-wordpress/).*

[LIVE BLOCK LINK](https://nexterwp.com/nexter-blocks/builder/wordpress-ajax-search-bar/)

## Before You Start

- **Edition:** Free. Measured with Nexter Blocks Pro deactivated, the Search Bar renders identically — form, input, dropdowns, suggestions and results all work without Pro.- **Block to enable:** Search Bar, switched on under **Nexter > Blocks** in your WordPress dashboard.- **Posts with tags applied.** The dropdown is built from your tag terms.

## Steps

- Select your **Search Bar** block and add a **filter field** with **taxonomy** as its source.

![Adding a taxonomy filter field](https://nexterwp.com/wp-content/uploads/2026/09/sb-field-tax-tag.webp)

- Choose **Tag** as the taxonomy, then publish and try it.

![Choosing the tag taxonomy](https://nexterwp.com/wp-content/uploads/2026/09/sb-fe-bytag.webp)

## How It Behaves

- **The dropdown lists your live tags.** Measured on a site with eight tags, the dropdown rendered 9 options including the All entry.- **Choosing a tag adds a taxonomy condition to the query**, exactly as the category filter does.- **Tags render flat.** Unlike categories they have no hierarchy, so there is nothing to indent.- **Each option can show its post count.**- **Only the title is searched by default.** Measured: with the default settings a term matched 4 posts by title; switching the search fields off entirely fell through to WordPress's own query and matched 15.- **It degrades to an ordinary search.** The block renders a real `<form method="get">` pointing at your site root, so with JavaScript disabled the bar still submits and lands on WordPress's own search results.

## Limitations

- **Tags with no posts still appear** in the dropdown and return nothing when chosen.- **A long tag list makes a long dropdown.** Sites that tag heavily end up with a dropdown that is hard to scan, which is an argument for filtering by category instead.- **One tag at a time.** There is no multi-select.- **The tag narrows, it does not search.** The typed term still has to match a field.

## Troubleshooting

### The tag dropdown is empty

No tags exist yet, or the taxonomy was not selected on the filter field.

### Choosing a tag returns nothing

Either no post carries that tag, or the typed term does not match any searched field on the posts that do.

### I want both a category and a tag filter

Add two filter fields, one per taxonomy. Each renders its own dropdown.

## Related Docs

- [Add a search bar in WordPress](https://nexterwp.com/docs/add-a-search-bar-in-wordpress/)- [Search by post category](https://nexterwp.com/docs/search-by-post-category-in-wordpress/)- [Limit search by a taxonomy term](https://nexterwp.com/docs/limit-wordpress-search-by-a-taxonomy-term/)- [Search WooCommerce products by tag](https://nexterwp.com/docs/search-woocommerce-products-by-tag-in-wordpress/)- [Add a search bar for posts](https://nexterwp.com/docs/add-search-bar-for-posts-in-wordpress/)