Configuring SEO for PLPs and PDPs
Configuring SEO settings for Product Listing Pages (PLPs) and Product Details Pages (PDPs) is essential for improving search engine visibility and discoverability. This guide walks you through setting up title and description templates for PLPs and PDPs and provides best practices for optimizing SEO performance.
Before you begin
For FastStore to use the
metaTagDescription field configured per product in the Catalog on PDP pages, a feature flag must be enabled for your store account in Intelligent Search. This flag allows Intelligent Search to include metaTagDescription in its link requests, which FastStore then uses as the page meta description.Without this flag enabled, FastStore will not receive the product-level
metaTagDescription from Intelligent Search and will fall back to the product's long description or the template configured in discovery.config.js. To enable this feature flag for your account, open a ticket with VTEX Support.SEO metadata
FastStore follows a structured approach to generating SEO metadata for PLPs and PDPs, prioritizing available catalog data before falling back to predefined templates in the
discovery.config.js file.Title
Title template
Description template
For FastStore to retrieve themetaTagDescriptionfrom the Catalog for PDP pages, the Intelligent Search feature flag must be enabled for your account. See Before you begin.
Instructions
- Open your FastStore project in a code editor of your preference.
- Go to the
discovery.config.jsfile and in theseosection add the following:
_12..._12seo: {_12 ..._12 plp: {_12 titleTemplate: '%s | FastStore PLP',_12 descriptionTemplate: '%s products on FastStore Product Listing Page',_12 },_12 pdp: {_12 titleTemplate: '%s | FastStore PDP',_12 descriptionTemplate: '%s products on FastStore Product Detail Page',_12 },_12},
Change the values intitleTemplateanddescriptionTemplateaccording to your needs. Use%sas a placeholder for the PLP and PDP title/name.
- Title template: This template will be applied to all PLPs and PDPs, including collections, categories, subcategories, and brands.
- Description template: This template is used for
collections, as descriptions forcollectionsare not configured in the Catalog. If a specific description isn't configured in the Catalog for a category, subcategory, or brand, this template will be used as a fallback.
Lazy loading and SEO considerations
FastStore uses lazy loading to improve performance. However, certain custom sections, such as those containing H1 headers, may need to appear in the initial HTML for SEO purposes, as search engine crawlers may not index dynamically loaded content. To optimize SEO for PLPs and PDPs, see the Optimizing SEO by managing Lazy Loading on PLPs and PDPs guide.