Easy 2 Fix – Google Custom Search Engine Search Box Not Showing

If your Google custom search engine search box not showing, we suggest you check a few things. The search box may begin to show up again.

Integrating Google Custom Search Engine (CSE) into your website or blog is a pretty easy thing to do. Just open a Google account, go to the CSE page, create a new search engine, get the code, and paste it into your website but what to do if google custom search engine search box not showing on your blog or website?

Advertisement

It’s easy, and you get all the benefits of using Google custom search engine on your website

One of the most annoying problems is that the Google custom search engine search box not showing, and you get no idea why this is happening. We have noticed two small mistakes, which, if made, can make the Google custom search engine search box not showing or disappear.

You may also like to read:

Google Custom Search Engine Search Box Not Showing

Google Custom Search Engine (CSE) Search Box Not Showing On Website?

Fix Google custom search engine search box not showing on website in 33 minutes

  1. Click on my ads

    Sign in to Adsense and then click on my ads tab. Click on search >>> Then custom search engines.
    After that, click on the new custom search engine.

  2. Provide name

    Provide the name for your custom search engine. After that, select ONLY SITES I SELECT. Then easily specify your website name.

  3. Modify options

    Modify the below options as you need. Custom Channel >>> Search box style >>> Themes

    Advertisements
  4. Confirm settings

    Under Search results option, make sure to have the below settings correct:
    Search results: ON MY WEBSITE ONLY
    URL where search results will be displayed: Your blog’s specified search results page.

  5. Save settings

    If you select the Two Column layout, click on the Save button and save and get both codes.
    1. SEARCH BOX CODE
    2. SEARCH RESULTS CODE

    After that, go to your site and create a specified search page.

  6. Paste results code

    On the search page paste the search results code and click save.

  7. Paste search code

    Go to appearance >>>  Widgets section and paste search box code and click save.

Please Review The Documents Below From Google For Guidance

1. https://developers.google.com/

Advertisements

2. https://developers.google.com/custom-search/docs/

3. https://developers.google.com/custom-search/docs/tutorial/

Include Google Custom Search Engine (CSE) to WordPress Site

You can use Google’s reliable and powerful search feature instead. It is free, allows you to limit the search to your sites only, and can be run from your own site but what to do if Google custom search engine search box not showing?

Google Custom Search Engine (CSE) Search Box Not Showing On Website
Google Custom Search Engine Search Box Not Showing

Let’s Understand Problems and Their Solutions

The default WordPress search feature is not very useful. It often fails to find relevant results. This forces site owners to look for alternatives.

Reason 1: Unclosed Form Tag in CSE

If you have another form on your web page and forget to close the CSE form tag, the CSE search box may not appear (especially if the CSE code is coming after another form). Forgetting to close the form tag with </form> is a common mistake made by web developers. See if that is the case with you too to fix Google custom search engine search box not showing error.

For implementing a Custom Search Engine on your webpage, google provides you with a three-part code. These parts are:

Advertisements
  • A JavaScript code
  • Search box markup ( <gcse:searchbox></gcse:searchbox> )
  • Search result markup ( <gcse:searchresults-only></gcse:searchresults-only> )

The search box markup and search results markup must appear on your webpage if search box markup fails to detect search results markup –the Google custom search engine search box not showing or not appear.

Why Do We Need a CSE Custom Search Engine?

Google Custom Search Engine Search Box Not Showing
Settings – Google Custom Search Engine Search Box Not Showing

It’s very critical to provide better search functionality on site. Usually, the main page contains post less than 10, but your blog users may get the best-related articles from Search only in most cases.

Plus, much Faster Search results than default WordPress Search + Good for your site’s SEO as Google knows this result list from the search query and doesn’t add it to a duplicate content list.

In WordPress, for example, every theme has various types of web pages, namely post, page, category, etc. Usually, people add search box markup in the HEADER portion of the code. 

You’ll need to add the search results markup in the code of every type of page at a position where you wish to show Google’s search results. If you add this markup only, say, in the file that displays post (mostly single.php) –the search box will not appear in other types of web pages.

Interesting articles for you:

Google Custom Search Engine Search Box Not Showing Error

  1. How to install and activate the WP Google Search plugin?

    To get a Google Custom Search field on your website, you first need to install and activate the plugin. You can do this by jumping over to the Plugins page in the WordPress admin dashboard. Use the search field provided and search the plugin wp google search. When it pops up, please install and activate it from there.

  2. How to get google search engine ID?

    Google Custom Search Engine (CSE) Search Box Not Showing On Website

    Once on the settings page, you will have some options to fill out. However, the first thing you need to do is get a Google Search Engine ID. You can see at the very top of the settings page there is a box. Use the link provided and get your ID from there. The process is simple.

    Advertisements
  3. How to create a page for search results for google custom search?

    Now that you have your ID in place, you can go ahead and finish configuring the settings page. There are some options you can choose from. One of the more important ones to pay attention to is the “Search Page Target URL” field.
    This is the page you have created for search results. When someone uses Google Custom Search on your website, they will be bounced to another page within your site to get results. So set the page you have created for that here.

Final Solution – Google Custom Search Engine Search Box Not Showing

If everything fails, we recommend using the code below to fix the Google custom search engine search box not showing.

<script>
  (function() {
    var cx = '007334364937416712831:1tkzq0z0fvu';
    var gcse = document.createElement('script');
    gcse.type = 'text/javascript';
    gcse.async = true;
    gcse.src = 'https://cse.google.com/cse.js?cx=' + cx;
    var s = document.getElementsByTagName('script')[0];
    s.parentNode.insertBefore(gcse, s);
  })();
</script>

Code Source: freecodecamp

And then in the “HTML Embed” sections in your design, only

<gcse:searchbox-only></gcse:searchbox-only>

or

<gcse:searchresults-only></gcse:searchresults-only>

Conclusion – Google Custom Search Engine Search Box Not Showing

Google Custom Search in WordPress will deliver the power of the most popular search engine in the world to the hands of your visitors. With the incredible level of customization, you can deliver a unique experience to those who use the system. Take your site further by offering Google Search on a WordPress site that is both engaging and highly accurate.

Google CSE is a good tool to enhance your site. Visitors will get better search results. Moreover, you can monetize your site results using Google Adsense.

We hope this article was useful for you and saved you some time. Please let me know if you have any questions on this topic.

Advertisements

Want more stuff like this?

Get the top best and trending articles and stories straight into your inbox!

Don't worry; we don't spam

Leave a Comment