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

Webpage not indexed by google because of unknown host DNS error

· 52CE 我爱测

I have hosted a site on github and encounter the following error in the Google Search Console URL inspection section. The custom domain I'm using was purchased through Google Domains. How can I enable google indexing of my site? …

问题原文

原帖链接 · The Nightman · CC BY-SA 4.0

I have hosted a site on github and encounter the following error in the Google Search Console URL inspection section.

The custom domain I'm using was purchased through Google Domains. How can I enable google indexing of my site?

Below is information about my DNS setup that might be helpful.

Below is the updated DNS setup.

已采纳解答

原帖链接 · Stephen Ostermiller · CC BY-SA 4.0

Of your DNS records, only one of them doing you any good. Keep this one for sure:

  • CNAME www.example.com

your TXT DNS record is not relevant for directing visitors to your site. It looks like it is used for HTTPS certificate generation. I wouldn't touch it either.

Your other three records are not good and should be removed:

  • HTTPS example.com -- HTTPS DNS records are only in a draft specification and should not be used. You should remove this record.
  • CNAME https://.example.com -- CNAME records should never contain https:// as part of the host name. You should remove this record.
  • CNAME https://www.example.com -- CNAME records should never contain https:// as part of the host name. You should remove this record.

You need to add the following record:

  • Type: A

  • Hostname: example.com (use your real domain name, without www. and without https://)

  • Values (These come from Github's documentation):

    185.199.108.153
    185.199.109.153
    185.199.110.153
    185.199.111.153
    

See GitHub's documentation about the apex of the domain for details

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

资料来源与适用范围

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

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

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