How to Add Search Form to WordPress Main Menu

Many excellent and popular WordPress themes don’t automatically add a search button or form to the main menu for desktops and mobile devices.

Although these themes have great features, and you’d like to continue using them to run your blogs without the search bar in the menu, the only other option is to add the search form to the sidebar via the WordPress widget.

Suppose you’re using a mobile device and want to search for content on the page. The search button is usually at the bottom of the screen since that’s why most mobile sidebars are placed.

For those looking for an easy option to add the search button to the main menu on both desktop and mobile devices, this post should help you do that.

It shows you how to add a search form to the main menu (top navigation menu) on desktops and mobile devices so users can quickly search for content on the page or site.

When you’re ready to add the search form, please follow the steps below:

Add WordPress Plugin

If you’re new and don’t know how to develop or modify your WordPress theme to add a custom search to the main menu, your other option will be to use a plugin.

A very good plugin to use is Ivory Search.
That might be other good plugin options, but the one above works great on most WordPress themes. Go to your WordPress admin dashboard, navigate to Plugin — Add New, and then search for Ivory Search.

Select install it.

Add Search form to Main Menu

Now that the plugin is installed. navigate to Ivory Search ==> Settings

Then select the Primary Menu to display the search form. Also, select the form style to use. The Sliding option provides optimal space options, especially for mobile devices.

WordPress main menu search button

When you’re done, click the Save button.

Now, look at your main menu to see if the search for shows on it. Suppose you’re satisfied with your settings. You can close out. If now, go back to the settings page and configure more advanced settings.

You can define the search post types, search form style, search menu locations, manage mobile displays for search, and more.

You can also upgrade to take advantage of other features that are not available in the free version.

Main Menu search form

That’s it!

I hope this post helped you add a search to your WordPress blog main menu on desktop and mobile devices.

You may also like the post below: