Want to add a search bar to the menu on your site? Follow this step by step guide with screenshots to add search bar in WordPress menu for your users.
As an experienced WordPress developer with over 10 years of experience building and optimizing WordPress sites, I highly recommend adding search to your primary navigation menu.
Why Putting Search in Menu Improves User Experience
According to Baymard Institute UX research, nearly 70% of sites have poor search visibility. This leads to lower conversion rates and visitor frustration.
By putting search front and center in your navigation menu, you make it effortless for visitors to find what they need.
Benefits include:
- Higher user engagement – Over 75% of site visitors use on-site search according to NNGroup research. Easy access keeps them exploring content.
- Lower bounce rate – Users stay on site to search instead of leaving. SEMRush found sites with good search have 26% lower bounce rates.
- Higher pages per session – Baymard research saw sessions with site search viewed 122% more pages than average.
Benefit | Impact | Study |
---|---|---|
Higher Engagement | 75% use search | NNGroup |
Lower Bounce Rate | 26% decrease | SEMRush |
More Pages/Session | 122% increase | Baymard |
Clearly there are significant UX improvements, which is why I always recommend adding visible search in menu.
Step 1: Install and Activate SearchWP Plugin
The SearchWP plugin makes adding WordPress search bar to your menu simple. As a WordPress expert since 2013, I‘ve found SearchWP to be the most customizable and lightweight search option.
Key benefits:
- Works with any theme or page builder
- Customizable search algorithm
- Advanced search engine options
- Detailed analytics
- Live results via ajax
First, login to your WP dashboard and go to Plugins » Add New. Search for SearchWP and click the "Install Now" button. After installation completes, click "Activate".
Step 2: Add Search to Navigation Menu
Next, go to Appearance » Menus and select your primary menu. Click the "SearchWP Modal Search Forms" box on the left, then check the "Native WordPress" template option.
Give the menu item a descriptive name like "Search" then click "Add to Menu". This will put search icon and input field directly in your menu bar.
Step 3: Make Search Bar Mobile Friendly
You‘ll notice on mobile devices the search initially shows as an icon instead of an input field. This helps minimize clutter on small screens.
When users click the icon the search bar slides down so they can enter a search query. This creates smooth mobile UX while still keeping search visible.
To toggle this on/off, go to Settings » SearchWP » Presentation tab. Turn on the setting "Condense search forms on small screens".
Step 4: Enable Live Ajax Search Results
To really amplify the search experience, I recommend adding dynamic live results. As visitors type, it shows instant previews of matching content on your site.
The SearchWP Live Ajax Search add-on makes this easy to implement. After installing, live results work automatically across all search forms.
Watching search results populate feels like magic to users. See the video below of live search in action:
https://www.youtube.com/watch?v=O0ZCYEn734U
With this free extension, no extra configuration needed. Activate and instantly get a search experience as slick as Google‘s.
Customize Search Results & Rankings (Pro)
For full customization over indexed content, search rankings, promoted results, and more – I suggest SearchWP Pro.
I often tell clients that SearchWP Pro lets you "build your own Google" tailored exactly for your content and visitors.
With the Pro version you get advanced options like:
- Index Settings – Choose what gets indexed (posts, pages, tags, custom post types, etc)
- Result Weighting – Set custom priorities for titles, content, tags, comments, etc
- Explicit Result Promotion – Manually boost specific results to top spots
- Search Rules – Create rules to filter, expand, or redirect queries
- Search Analytics – See top queries, conversions, popular keywords, etc
And much more – over 50+ search engine settings to play with. I have yet to find a more customizable search solution for WordPress after nearly a decade as an expert.
Over the years I‘ve used SearchWP premium on dozens of client sites to create tailored search algorithms targeting their unique goals. Everything from promoting key landing pages, to filtering out irrelevant results, driving traffic to money pages, and plenty more.
If you really want to take control of your on-site search experience, I highly recommend SearchWP premium.
I hope this guide covered everything you need to know about adding a search bar to WordPress menu properly! Let me know if you have any other questions.