ecommerce-seo
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseE-commerce SEO
电商SEO
Overview
概述
E-commerce SEO covers the technical and content foundations that help search engines understand and rank your product pages: meta tags, structured data (JSON-LD), canonical URLs, XML sitemaps, and Core Web Vitals. Shopify and WooCommerce handle most technical SEO automatically; your effort should focus on optimizing titles, descriptions, and structured data quality — not plumbing.
电商SEO涵盖了帮助搜索引擎理解产品页面并为其排名的技术和内容基础:元标签、结构化数据(JSON-LD)、规范URL、XML站点地图,以及Core Web Vitals。Shopify和WooCommerce会自动处理大部分技术SEO工作,你应该重点优化标题、描述和结构化数据质量,而非底层基础配置。
When to Use This Skill
适用场景
- When building product pages that need to rank in Google Shopping and organic search
- When implementing JSON-LD structured data for rich snippets (price, availability, reviews)
- When handling canonical URLs for products with multiple variants or filter combinations
- When generating XML sitemaps for a large catalog (10K+ products)
- When diagnosing why products are not appearing in Google Shopping rich results
- 当你搭建需要在Google Shopping和自然搜索中获得排名的产品页面时
- 当你为富摘要(价格、库存状态、评论)实现JSON-LD结构化数据时
- 当你为有多款变体或多筛选条件组合的产品处理规范URL时
- 当你为大型商品目录(1万+产品)生成XML站点地图时
- 当你排查产品未出现在Google Shopping富结果中的原因时
Core Instructions
核心操作指南
Step 1: Check what your platform handles automatically
步骤1:确认你的平台已自动处理的功能
Before installing anything, understand what is already built in:
| Feature | Shopify | WooCommerce | BigCommerce |
|---|---|---|---|
| XML sitemap | Auto-generated at | Auto-generated at | Auto-generated at |
| Canonical URLs | Yes (built-in) | Yes (with Yoast SEO) | Yes (built-in) |
| Meta title/description editing | Yes (via product editor) | Yes (via Yoast SEO fields) | Yes (via product editor) |
| JSON-LD product schema | Basic (varies by theme) | Requires WooCommerce + Yoast or Rank Math | Basic (varies by theme) |
| robots.txt | Editable in Online Store settings | Editable via file or Yoast | Editable via admin |
在安装任何工具前,先了解平台内置的功能:
| 功能 | Shopify | WooCommerce | BigCommerce |
|---|---|---|---|
| XML站点地图 | 自动生成,路径为 | 自动生成,路径为 | 自动生成,路径为 |
| 规范URL | 支持(内置) | 支持(安装Yoast SEO后) | 支持(内置) |
| 元标题/描述编辑 | 支持(通过产品编辑器) | 支持(通过Yoast SEO字段) | 支持(通过产品编辑器) |
| JSON-LD产品Schema | 基础支持(不同主题有差异) | 需要安装WooCommerce + Yoast或Rank Math | 基础支持(不同主题有差异) |
| robots.txt | 可在在线商店设置中编辑 | 可通过文件或Yoast编辑 | 可通过管理后台编辑 |
Step 2: Install an SEO foundation
步骤2:搭建SEO基础
Shopify
Shopify
Shopify handles sitemaps, canonicals, and basic schema automatically. Focus on:
- Install a SEO app for enhanced structured data and bulk editing:
- Yoast SEO for Shopify ($19/mo) — most comprehensive
- Schema Plus (free tier) — focused on JSON-LD structured data
- SEO Manager ($20/mo) — bulk meta editing + structured data
- Go to Shopify Admin → Online Store → Preferences and verify:
- Your homepage title and meta description are set
- Google Analytics is connected
- Go to each product's page in admin and fill in the SEO section at the bottom:
- Write unique meta titles following:
[Brand] [Product Name] - [Key Attribute] | [Store Name] - Write unique meta descriptions (150–160 characters) that include price range, key benefit, and a call to action
- Write unique meta titles following:
- Submit your sitemap to Google Search Console: go to search.google.com/search-console → Sitemaps → Add
yourstore.com/sitemap.xml
Shopify会自动处理站点地图、规范URL和基础Schema,重点关注以下内容:
- 安装SEO应用以获得增强的结构化数据能力和批量编辑功能:
- Yoast SEO for Shopify(19美元/月)—— 功能最全面
- Schema Plus(免费版)—— 专注于JSON-LD结构化数据
- SEO Manager(20美元/月)—— 元数据批量编辑+结构化数据功能
- 进入Shopify管理后台 → 在线商店 → 偏好设置,确认以下配置:
- 已设置首页标题和元描述
- 已连接Google Analytics
- 进入管理后台的每个产品页面,填写底部的SEO板块:
- 按照以下格式编写唯一的元标题:
[品牌] [产品名称] - [核心属性] | [店铺名称] - 编写唯一的元描述(150–160字符),包含价格区间、核心优势和行动号召
- 按照以下格式编写唯一的元标题:
- 向Google Search Console提交你的站点地图:进入search.google.com/search-console → 站点地图 → 添加
yourstore.com/sitemap.xml
WooCommerce
WooCommerce
- Install Yoast SEO (free) or Rank Math (free) from the WordPress plugin directory — these are required for proper WooCommerce SEO
- After installing Yoast SEO:
- Go to Yoast SEO → Search Appearance → WooCommerce and configure product page templates
- Enable JSON-LD structured data under Yoast SEO → Search Appearance → Schema
- Go to Yoast SEO → Tools → Bulk Editor to edit meta titles and descriptions for all products at once
- For enhanced product schema (price, availability, reviews):
- Install Rank Math which includes WooCommerce Product Schema with review aggregation built in
- Submit sitemap to Google Search Console: Yoast auto-generates
/sitemap_index.xml
- 从WordPress插件库安装Yoast SEO(免费)或Rank Math(免费)—— 这是实现WooCommerce规范SEO的必备工具
- 安装Yoast SEO后:
- 进入Yoast SEO → 搜索外观 → WooCommerce,配置产品页面模板
- 在Yoast SEO → 搜索外观 → Schema下启用JSON-LD结构化数据
- 进入Yoast SEO → 工具 → 批量编辑器,一次性编辑所有产品的元标题和描述
- 若需要增强版产品Schema(价格、库存、评论):
- 安装Rank Math,其内置了带评论聚合功能的WooCommerce产品Schema
- 向Google Search Console提交站点地图:Yoast会自动生成
/sitemap_index.xml
BigCommerce
BigCommerce
- BigCommerce includes basic SEO features built-in. Go to BigCommerce Admin → Products → [Edit Product] → SEO tab
- For enhanced structured data: install SEO Expert from the BigCommerce App Marketplace
- Go to Store Setup → Search Engine Optimization to configure global defaults
- Submit your sitemap at to Google Search Console
yourstore.com/xmlsitemap.xml
- BigCommerce内置了基础SEO功能,进入BigCommerce管理后台 → 产品 → [编辑产品] → SEO标签页
- 如需增强结构化数据:从BigCommerce应用市场安装SEO Expert
- 进入店铺设置 → 搜索引擎优化配置全局默认规则
- 向Google Search Console提交你的站点地图,路径为
yourstore.com/xmlsitemap.xml
Custom / Headless
自定义/Headless
For headless storefronts, implement structured data manually. Serve JSON-LD on every product page:
typescript
function buildProductJsonLd(product: Product, reviews: ReviewSummary) {
return {
'@context': 'https://schema.org',
'@type': 'Product',
name: product.title,
image: product.images.map(img => img.src),
description: product.metaDescription || product.description.slice(0, 200),
sku: product.variants[0]?.sku,
brand: { '@type': 'Brand', name: product.vendor },
offers: product.variants.length === 1
? {
'@type': 'Offer',
url: `https://yourstore.com/products/${product.slug}`,
priceCurrency: 'USD',
price: (product.variants[0].priceInCents / 100).toFixed(2),
availability: product.variants[0].inventoryQuantity > 0
? 'https://schema.org/InStock'
: 'https://schema.org/OutOfStock',
}
: {
'@type': 'AggregateOffer',
lowPrice: (Math.min(...product.variants.map(v => v.priceInCents)) / 100).toFixed(2),
highPrice: (Math.max(...product.variants.map(v => v.priceInCents)) / 100).toFixed(2),
priceCurrency: 'USD',
offerCount: product.variants.length,
},
...(reviews.count > 0 ? {
aggregateRating: {
'@type': 'AggregateRating',
ratingValue: reviews.average.toFixed(1),
reviewCount: reviews.count,
bestRating: '5',
},
} : {}),
};
}For canonical URL handling on variant pages — strip variant parameters:
typescript
// Always use the base product URL as canonical
// /products/blue-widget?variant=123 → canonical: /products/blue-widget
function getCanonicalUrl(path: string): string {
// Strip variant query parameters
return `https://yourstore.com${path.split('?')[0]}`;
}For large catalogs (10k+ products), use a sitemap index:
typescript
// Serve /sitemap.xml as a sitemap index pointing to paginated product sitemaps
// Each child sitemap: max 50,000 URLs
// Regenerate every 6 hours or on product publish/unpublish events对于Headless店面,需要手动实现结构化数据,在每个产品页面提供JSON-LD:
typescript
function buildProductJsonLd(product: Product, reviews: ReviewSummary) {
return {
'@context': 'https://schema.org',
'@type': 'Product',
name: product.title,
image: product.images.map(img => img.src),
description: product.metaDescription || product.description.slice(0, 200),
sku: product.variants[0]?.sku,
brand: { '@type': 'Brand', name: product.vendor },
offers: product.variants.length === 1
? {
'@type': 'Offer',
url: `https://yourstore.com/products/${product.slug}`,
priceCurrency: 'USD',
price: (product.variants[0].priceInCents / 100).toFixed(2),
availability: product.variants[0].inventoryQuantity > 0
? 'https://schema.org/InStock'
: 'https://schema.org/OutOfStock',
}
: {
'@type': 'AggregateOffer',
lowPrice: (Math.min(...product.variants.map(v => v.priceInCents)) / 100).toFixed(2),
highPrice: (Math.max(...product.variants.map(v => v.priceInCents)) / 100).toFixed(2),
priceCurrency: 'USD',
offerCount: product.variants.length,
},
...(reviews.count > 0 ? {
aggregateRating: {
'@type': 'AggregateRating',
ratingValue: reviews.average.toFixed(1),
reviewCount: reviews.count,
bestRating: '5',
},
} : {}),
};
}对于变体页面的规范URL处理,移除变体参数:
typescript
// Always use the base product URL as canonical
// /products/blue-widget?variant=123 → canonical: /products/blue-widget
function getCanonicalUrl(path: string): string {
// Strip variant query parameters
return `https://yourstore.com${path.split('?')[0]}`;
}对于大型商品目录(1万+产品),使用站点地图索引:
typescript
// Serve /sitemap.xml as a sitemap index pointing to paginated product sitemaps
// Each child sitemap: max 50,000 URLs
// Regenerate every 6 hours or on product publish/unpublish eventsStep 3: Optimize product titles and descriptions
步骤3:优化产品标题和描述
This is the highest-ROI SEO work. Follow these title formats:
- Product title format:
[Brand] [Product Name] [Key Attribute] - [Store Name]- Example: "Nike Air Max 90 White - Running Store"
- Meta description format: Include price range, key benefit, and CTA in 150–160 characters
- Example: "Shop Nike Air Max 90 from $120. Lightweight cushioning for daily runs. Free shipping on orders over $75. Shop now."
Common issues to fix:
- Duplicate meta titles across variants (fix: add variant-specific attributes to the title)
- Meta descriptions that are just the product description truncated (fix: write purposeful descriptions)
- Missing alt text on product images (fix: use format)
[Product Name] - [Color/View]
这是投入产出比最高的SEO工作,遵循以下标题格式:
- 产品标题格式:
[品牌] [产品名称] [核心属性] - [店铺名称]- 示例:"Nike Air Max 90 White - Running Store"
- 元描述格式:在150–160字符内包含价格区间、核心优势和行动号召
- 示例:"Shop Nike Air Max 90 from $120. Lightweight cushioning for daily runs. Free shipping on orders over $75. Shop now."
需要修复的常见问题:
- 不同变体的元标题重复(修复方法:在标题中加入变体专属属性)
- 元描述只是截断的产品描述(修复方法:撰写针对性的描述)
- 产品图片缺少alt文本(修复方法:使用格式)
[产品名称] - [颜色/视图]
Step 4: Handle technical SEO issues
步骤4:处理技术SEO问题
Canonical URLs for filter pages:
- Collection pages with active filters () should use self-referencing canonicals
/collections/shoes?color=red - Pages with sort order only () should canonical back to the unfiltered collection URL
/collections/shoes?sort=price-asc
In Shopify, this is handled automatically. In WooCommerce with Yoast, go to Yoast SEO → Search Appearance → Taxonomies and configure canonical behavior for filtered pages.
Robots.txt — block these paths:
- and
/cart— not indexable/checkout - and
/account— not indexable/search? - Collection filter combinations with 3+ active filters — use meta tag
noindex, follow
In Shopify: Online Store → Themes → Edit Code → robots.txt.liquid
In WooCommerce: Yoast SEO manages robots.txt automatically
筛选页面的规范URL:
- 带激活筛选的集合页面()应使用自引用规范
/collections/shoes?color=red - 仅带排序参数的页面()应规范指向未筛选的集合URL
/collections/shoes?sort=price-asc
在Shopify中这会被自动处理,在安装Yoast的WooCommerce中,进入Yoast SEO → 搜索外观 → 分类法配置筛选页面的规范行为。
Robots.txt — 屏蔽以下路径:
- 和
/cart— 不可被索引/checkout - 和
/account— 不可被索引/search? - 激活3个以上筛选条件的集合筛选组合 — 使用元标签
noindex, follow
在Shopify中操作路径:在线商店 → 主题 → 编辑代码 → robots.txt.liquid
在WooCommerce中:Yoast SEO会自动管理robots.txt
Step 5: Verify with Google tools
步骤5:使用Google工具验证
- Google Rich Results Test (search.google.com/test/rich-results): paste any product URL and verify structured data is correct
- Google Search Console: check for structured data errors under Enhancements → Products
- PageSpeed Insights: test Core Web Vitals — target LCP under 2.5 seconds, CLS under 0.1
- Google富结果测试(search.google.com/test/rich-results):粘贴任意产品URL,验证结构化数据是否正确
- Google Search Console:在增强功能 → 产品下检查结构化数据错误
- PageSpeed Insights:测试Core Web Vitals — 目标是LCP低于2.5秒,CLS低于0.1
Best Practices
最佳实践
- Write unique meta descriptions for every product — avoid duplicating the product title; include key attributes (size, material, price) that help click-through rate
- Compress and properly size product images — oversized images are the #1 cause of slow LCP scores; Shopify compresses automatically; WooCommerce use ShortPixel or Imagify plugin
- Use JSON-LD over microdata — easier to maintain and Google recommends it
- Set canonical URLs on every page — self-referencing canonicals prevent duplicate content from URL parameters
- Update sitemaps automatically — Shopify and WooCommerce + Yoast do this; for custom builds, regenerate on product publish/unpublish events
- Add image sitemaps — include product images with descriptive alt text for Google Image search traffic
- 为每个产品编写唯一的元描述 — 避免复制产品标题,包含有助于提升点击率的核心属性(尺寸、材质、价格)
- 压缩并调整产品图片至合适尺寸 — 过大的图片是LCP得分慢的首要原因;Shopify会自动压缩,WooCommerce可使用ShortPixel或Imagify插件
- 优先使用JSON-LD而非微数据 — 更易维护,也是Google推荐的方式
- 为每个页面设置规范URL — 自引用规范可避免URL参数导致的重复内容问题
- 自动更新站点地图 — Shopify和WooCommerce+Yoast会自动处理;自定义搭建的站点可在产品发布/下架时重新生成
- 添加图片站点地图 — 包含带描述性alt文本的产品图片,可获得Google图片搜索流量
Common Pitfalls
常见陷阱
| Problem | Solution |
|---|---|
| Products not appearing in Google Shopping rich results | Check Google Search Console → Enhancements → Products for structured data errors; use Rich Results Test to validate |
| Faceted navigation creating millions of indexable URLs | Shopify/WooCommerce handle this automatically with canonicals; for custom builds, use |
| Out-of-stock products returning 404 | Keep the page live at 200 status; show "out of stock" and suggest alternatives; remove from sitemap only if permanently discontinued |
| Schema.org validation errors | Test with Google's Rich Results Test; ensure price and availability are always present and correctly formatted |
| Slow Core Web Vitals hurting ranking | Preload hero images, compress product images, use lazy loading below fold; Shopify's CDN helps significantly |
| 问题 | 解决方案 |
|---|---|
| 产品未出现在Google Shopping富结果中 | 检查Google Search Console → 增强功能 → 产品下的结构化数据错误;使用富结果测试工具验证 |
| 分面导航生成数百万可索引URL | Shopify/WooCommerce会通过规范自动处理该问题;自定义搭建的站点可在多筛选条件页面添加 |
| 缺货产品返回404状态码 | 保持页面正常运行,返回200状态码;展示"缺货"提示并推荐替代产品;仅当产品永久停售时才从站点地图中移除 |
| Schema.org验证错误 | 使用Google富结果测试工具检测;确保价格和库存状态始终存在且格式正确 |
| Core Web Vitals得分低影响排名 | 预加载首屏图片、压缩产品图片、首屏以下内容使用懒加载;Shopify的CDN可大幅改善该问题 |
Related Skills
相关技能
- @google-shopping-feed
- @google-ads-ecommerce
- @content-commerce
- @social-proof-widgets
- @google-shopping-feed
- @google-ads-ecommerce
- @content-commerce
- @social-proof-widgets