站点收录案例讲解
站点做好SEO的关键在于做好页面抓取速度、提高搜索引擎点击量、提供稳定的服务器、页面尽量尝试提供html格式,有利于搜索引擎爬虫爬取。
- 站点robots.txt参考示例
User-agent: *
Allow: /
Sitemap: https://域名/sitemap.xml
Disallow: /static/js/
Disallow: /static/css/
Disallow: /static/picture/
- sitemap.xml示例
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
<url>
<loc>https://域名/</loc>
<lastmod>2025-08-26</lastmod>
<changefreq>weekly</changefreq>
<priority>1.0</priority>
</url>
<url>
<loc>https://域名/index1.html</loc>
<lastmod>2025-08-26</lastmod>
<changefreq>weekly</changefreq>
<priority>0.9</priority>
</url>
</urlset>