# SEO - how to get a search bar at google?

**URL:** https://meta.discourse.org/t/seo-how-to-get-a-search-bar-at-google/80394
**Category:** Support
**Created:** [12.Февраль.2018 18:07:17 UTC](https://meta.discourse.org/t/seo-how-to-get-a-search-bar-at-google/80394 "2018-02-12T18:07:17Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![j.jaffeux](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/j.jaffeux/32/60297_2.png) [@j.jaffeux](https://meta.discourse.org/u/j.jaffeux)
#### Post date: [12.Февраль.2018 18:34:09 UTC](https://meta.discourse.org/t/seo-how-to-get-a-search-bar-at-google/80394/3 "2018-02-12T18:34:09Z")

</div>

The URL of a search in discourse has the following format:

`https://your.domain.tld/search?q=test`

So I think if you added this to the body of a theme component (the only thing you have to change is your.domain.tld):

```plaintext
<script type="application/ld+json">
{
   "@context": "http://schema.org",
   "@type": "WebSite",
   "url": "https://your.domain.tld/",
   "potentialAction": {
     "@type": "SearchAction",
     "target": "https://your.domain.tld/search?q={search_term_string}",
     "query-input": "required name=search_term_string"
   }
}
</script>

```

It could eventually work, bear in mind, that in the end only google is deciding if this will show or not, so you could add this code and it would do nothing.

---

_[View the full topic](https://meta.discourse.org/t/seo-how-to-get-a-search-bar-at-google/80394)._
