Command Palette

Search for a command to run...

Customize Seed Data

In this guide, you'll learn how the starter's seed script builds regions, currencies, locales, and a demo catalog from JSON data files, and how to adapt them for your own markets and products.

The backend ships a one-off seed script, , instead of a generated migration. It checks whether the store is already seeded, then creates the store, regions, catalog, and translations in order. Each stage reads its own input from JSON files under .

The only existence check is the sales channel from . If you delete it and run the script again, every other stage runs again without checking for duplicates.

Regions and Currencies

Each file under is one region, for example . The starter ships 241 of these, one per country.

To add or edit a region, copy an existing file and edit it. It needs , , , , and prices in /. Prices are keyed by a camelCase product handle or shipping option code, for example becomes . A new region needs a price for every existing product, and a new product needs a price entry in every existing region.

The default currency ( in ) must match one of your regions' currencies. Otherwise, the seed script refuses to run rather than leaving the store without a default currency.

Locales and Translations

Locale data follows the same pattern as regions, from , for example . The starter ships 36 locale files. To add a locale, add a JSON file with the same shape. It feeds translations for categories, collections, product options, products, variants, shipping options, and refund reasons.

This is a third, independent locale list. The storefront's own UI languages live in , and email languages live in . Adding a locale here doesn't add it to either of those.

Products, Categories, and Shipping Options

The demo catalog itself is plain JSON, not TypeScript. Categories, product options, products, and collections live in , and shipping options live in . A product references its category by handle and its options by title, so both must already exist in their own files. It also needs a price in every region's .

Running the Seed

Run the script from with , , or . From the repository root, does the same through the pnpm workspace. Every one of them runs , declared in .

Migration scripts load data from . If you seed from a build output rather than from the development server, copy into the build output alongside the compiled code.

Before You Go Live

  • Replace the demo categories, products, and collections in with your own catalog before you consider the store ready. and don't check for existing handles, so re-running the script after editing this data can create duplicates rather than update anything.
  • Trim down to your real target markets. Every file in that directory creates its own stock location, fulfillment set, and shipping options, so 241 regions means 241 of each.
  • Update in if the region backing it isn't one you kept.

References

Edited Aug 21, 2026·Edit this page