Based on Google’s documentation for Sitelinks Searchbox you need to start by creating a website data item for your homepage. From there you can use the potential action field to create a search action data item. You will want your website data item JSON-LD to look like this:

<script type="application/ld+json">


    "@context": "",

    "@type": "WebSite",

    "potentialAction": {

        "@type": "SearchAction",

        "target": "{search_term_string}",

        "name": "Search Example Site",

        "query-input": "required name=search_term_string",

        "@id": ""


    "url": "",

    "name": "Example Website",

    "@id": ""



This is what your search action data item will look like in the editor:

To verify the work that you’ve done, use the view json-ld feature within the editor. Then copy the markup and input it as code into Google’s Rich Results Tool