大网数据广告活动
网站运营与故障问答

Sitelink search box does not appear on Google after adding JSON-LD SearchAction to my site yesterday

· 52CE 我爱测

I added the JSON-LD code to my site but search bar did not appear. What is the reason for this? am i doing something wrong? <script type="application/ld+json"> { "@context": "https://schema.org", "@type": "WebSite", "url": "https…

问题原文

原帖链接 · emeksc1 · CC BY-SA 4.0

I added the JSON-LD code to my site but search bar did not appear. What is the reason for this? am i doing something wrong?

 <script type="application/ld+json">
        {
        "@context": "https://schema.org",
        "@type": "WebSite",
        "url": "https://www.example.com/",
        "potentialAction": {
        "@type": "SearchAction",
        "target": "https://www.example.com/search?term={search_term_string}",
        "query-input": "required name=search_term_string"
        }
        }
    </script>

已采纳解答

原帖链接 · Maximillian Laumeister · CC BY-SA 4.0

Google only displays the sitelinks search box for your domain if they feel like it, even if your markup is well-formed.

From Google's guidelines for searchbox structured data:

Important: Google doesn't guarantee that a sitelinks search box will be shown in search results. Additionally, using the sitelinks search box markup doesn't make it more likely that a sitelinks search box will be shown. For a list of common reasons why Google may not show structured data in search results, review the General Structured Data Guidelines.

If you've implemented the markup, the only thing left to do is wait and hope, and maybe improve your site's SEO in a very general sense.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Webmasters Stack Exchange
适用范围
以原帖系统、软件版本与发布日期为准(2020-05-29)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。