Skip to content

SEO

Everything lives in @kotao/storefront/seo (also re-exported from the root).

Return SEO data from your route’s meta chain with getSeoMeta:

import { getSeoMeta } from "@kotao/storefront";
export const meta: Route.MetaFunction = ({ data }) =>
getSeoMeta({
title: data.product.title,
description: data.product.summary,
});

The <Seo /> component (from /react) covers the render-side when you prefer a component.

JSON-LD builders for the common shapes: productJsonLd, organizationJsonLd, websiteJsonLd, breadcrumbListJsonLd, localBusinessJsonLd, restaurantJsonLd. Serialize with serializeJsonLd — it escapes for safe embedding in a <script> tag.

Add resource routes that return robotsResponse(options) and sitemapResponse / sitemapIndexResponse (or build the XML yourself with buildSitemapXml). They stay in your theme, so you control what is listed.

storefrontRedirect resolves merchant-configured URL redirects (managed in the Workspace) for unmatched paths — call it from your catch-all route before rendering the 404, so moved pages 301 instead of dead-ending.