Make the Site Visible on Google
Go to google search console.
Choose the “Domain” option. Enter the www.yourdomain.com and click continue.
Copy the “TXT record”, go to domain DNS provider. Add new TXT resource record.
For Namesilo, click create TXT resource record, put what you just copied to the TEXT column and leave the hostname column blank.
After verfiying and being able to enter google search console. Go to blog root directory, run
npm install hexo-generator-sitemap --save
.Go to
_config.yml
and add
1 | # Auto generate sitemap |
When Hexo generates the website, there will be a
sitemap.xml
file in thepublic
directory. Go to google search console, under index->sitemaps, add the URL (for me https://www.sungwa.com/sitemap.xml). If success, the status will be “Success”.After a while, search
site:yusungwa.com
in google, it would show the result.
Aside: I also changed both the URL in hexo and theme’s
_config.yml
to my domain https://yusungwa.com.