How to add search box in websites google search results using “Sitelinks Searchbox” ?

Have you ever seen, for some websites we seen a search box appearing inside google search results like as below,


Above is just an example to demo, how the search box inside google search results looks like, when you searched “pinterest” in google and you can see an another search box appearing in google search results, which allows users to type another search text, as seen where user can type “pizza” which will actually search for text “pizza” only on without browsing to website and then going to search.

Google Search can expose a search box scoped to your website when it appears as a search result. This search box is powered by Google Search. However, if you wish to power this search box with your own search engine, or if you want search results also to include an associated mobile app, you can do so using structured data embedded on your website.

To implement this feature, you will need following things,

  • Access to edit source code of your websites home page
  • Properly setup search mechanism on your website, if you don’t have setup search mechanism in your website, you can setup the same using “google custom search engine

Here, we have setup the search mechanism at out another website searching the queries as

Copy the below code and paste it into your website home page as, Note: This code needs to be pasted only on home page and not on any other page, and in “head” html tag.

<script type="application/ld+json"&gt;
   "@context": "",
   "@type": "WebSite",
   "url": "",
   "potentialAction": {
     "@type": "SearchAction",
     "target": "{search_term}",
     "query-input": "required name=search_term"

In the above link, change “” to actual link of your website.

You can test your above structured data using after editing the home page and then enter the home page url to this tool and it should show “0 Errors, 0 Warnings”

More reference :

How to Add meta Search Engine x
How to Add meta Search Engine

Leave a Comment

Sign up to our newsletter!

ADB Commands Android Android Applications Android Build system Application Libraries Application Stack / User Interface Bash / Shell Scripts Bluetooth driver Cloud Technologies Commands and Packages Compilation Content Management System Core Kernel C Programs Development, Debugging and Performance Tools Development and Build Development Environment Setup Django & REST Api Errors & Failures Git Hardware Platforms HTML JAVA Programs Linux, OS Concepts and Networking Linux Device Drivers Linux Host, Ubuntu, SysAdmin Linux Kernel Linux Networking Middleware Libraries, HAL Multimedia NDK / Middleware / HAL Operating System Concepts PHP Programming Languages Scripting and Automation Search Engine Optimisation ( SEO ) Social Media Source Code Management ( SCM ) System Administration, Security Testing and Debugging Uncategorized Web Design and Development Website Hosting Wordpress Yocto Embedded Linux