Metafields store details that belong to one product or variant, such as fit, dimensions or care instructions. Metaobjects store content that many products share, such as a size guide or an ingredient profile, and products point to them. Move specs out of descriptions and into both, and your theme, filters, translations and feeds all read the same structured data.
Metafields vs metaobjects: what each is for
A metafield is a custom field attached to a Shopify resource: a product, variant, collection, customer, order, page or the shop. You create a definition once (name, namespace and key, type, validation), and every product gets that field in the admin. A value like specs.fit = "Relaxed" lives on that one product.
A metaobject is a custom content type with its own fields and entries. You define “Size guide” with a name, measurements and fit notes, create one entry per guide, then point each product to the right entry through a metaobject reference metafield. Edit the entry once and every product that references it updates.
| Product description | Tags | Metafield | Metaobject | |
|---|---|---|---|---|
| Structure | Free-form HTML | Free text | Typed field with validation | Typed fields, reusable entries |
| Best for | Story and selling copy | Internal flags, automations | Details unique to a product or variant | Content shared across many products |
| Usable as a filter | No | Yes, but messy | Yes, for supported types | Yes, through reference metafields |
| Survives a redesign | Only as one blob | Yes | Yes | Yes |
| Translation | Whole block at once | Not practical | Per field | Per entry |
The rule of thumb: if the value differs on nearly every product, it’s a metafield. If you’d otherwise paste the same block into dozens of products, it’s a metaobject.
Planning your product data model
Messy setups come from creating fields one request at a time. Plan the model first.
- Inventory your descriptions. Pull 20 to 30 products across your main categories and list every distinct piece of information: materials, dimensions, care, ingredients, warnings, what’s in the box.
- Decide the level of each field. Product-level if it’s true for every variant (fit), variant-level if it changes by option (weight per size).
- Pick the narrowest type that fits. A dimension type instead of text for “Width: 40 cm”, an integer for piece count, true or false for “vegan”. Typed values are what filters and feeds can use.
- Mark shared content as metaobjects. Size guides, ingredients, designers, certifications.
- Name for the long term. Use a consistent namespace and plain keys (
specs.fit,specs.width), never names tied to a theme section or campaign. - Record where each field is used, so you know what breaks if someone changes it.
A simple model sheet keeps everyone aligned:
| Field | Level | Type | Shared? | Used in |
|---|---|---|---|---|
| Fit | Product | Single line text, preset choices | No | PDP, filter |
| Width | Variant | Dimension | No | PDP, comparison table |
| Size guide | Product | Metaobject reference | Yes | PDP drawer |
| Key ingredients | Product | List of metaobject references | Yes | PDP, filter, glossary |
| Vegan | Product | True or false | No | Filter, feed |
Before creating custom definitions, check what Shopify already provides. Shopify has been rolling out category metafields tied to its standard product taxonomy: assigning a product category can suggest attributes like color, size and material, designed to work with filters and sales channels. Shopify also offers standard definitions for some common fields, such as review ratings. Use them instead of inventing parallel custom fields.
Common uses: specs, size guides, ingredients and FAQs
Specs
Technical specs belong in individual metafields, not a pasted table. As fields, they render as the same spec list on every product, and a comparison table across a collection needs no retyping. Use the dimension, weight and volume types so the unit is stored with the value.
Size guides
A size guide is the classic metaobject. Create a definition with a name, a measurements field and fit notes, make one entry per garment type, and reference the right entry from each product. When a pattern changes, you update one entry instead of every affected description.
Ingredients and materials
For beauty, food and supplement brands, make each ingredient a metaobject entry with a name, a short description and notes like allergen information. Products reference a list of ingredients. The same entries feed the product page, filters like “contains niacinamide” and, because metaobject entries can be published as their own web pages with a theme template, an ingredient glossary.
FAQs
Product FAQs work well as metaobjects: each entry holds a question and an answer, and products reference a list of them. Shipping or warranty questions are written once; product-specific ones get their own entries.
Connecting metafields to theme sections without code
In an Online Store 2.0 theme, many section and block settings can pull their value from a metafield. In the theme editor, open the product template, select a block such as a text block or collapsible row, and click the “Connect dynamic source” icon next to the setting. The editor lists every metafield whose type matches.
Common no-code connections:
- A text block under the title showing fit or material
- A collapsible row filled from a care-instructions rich text metafield
- An image block pulling a product-specific diagram from a file metafield
Three limits to know. First, you can only connect to the blocks and setting types your theme exposes. Second, rendering a metaobject’s full structure, like a size table or an ingredient grid, usually needs a small custom Liquid section. That’s a one-time build: once it exists, merchandisers manage content in the admin and nobody touches code. Third, check what each block does when a connected field is empty. Some themes hide the block; others leave an orphaned heading.
What to show on the product page, and in what order, is its own decision; product page optimization covers it.
Using metafields in filters and search
Shopify’s Search & Discovery app lets you add product and variant metafields as storefront filters, next to built-in options like availability, price and vendor. Filters only work with certain types, mainly single line text, numbers, true or false and metaobject references, plus lists of those. Rich text and JSON can’t become filters, so choose types carefully during planning.
What makes metafield filters work in practice:
- Consistent values. “Navy”, “navy” and “Navy blue” become three filter options. Preset choices or metaobject references prevent this.
- Full coverage. Products with a blank field vanish as soon as a shopper picks any value. Fill the field across the collection before switching the filter on.
- Clean labels. The filter shows the stored value, so store “Linen”, not “100% linen, stonewashed for softness”.
Which filters to show on which collections is a merchandising call; collection page optimization walks through it.
Search needs its own check, because metafield values aren’t always indexed. Search your storefront for a term that only exists in a metafield. If nothing comes back, check whether your search app can include metafields, or make sure key terms also appear in titles or tags.
Feeding structured data to Google and marketplaces
Google Merchant Center, Meta catalogs and marketplaces ask for attributes like color, size, material, gender and age group, and missing or vague values limit where products show. Metafields keep them in one place.
Three routes get them out:
- Shopify’s channel apps. The Google & YouTube and Facebook & Instagram apps read core product fields, and some attributes can come from metafields the app recognizes. Check each app’s mapping rather than assuming a metafield syncs.
- A feed management app. Most feed tools can map any metafield to any feed attribute and apply rules, such as building titles from brand, product type and material. For large or multi-channel catalogs, this is the most flexible route.
- On-page structured data. A developer can add metafield values like material or pattern to your theme’s Product structured data, so the page and the feed describe the product the same way.
Metafields can also carry internal data that never appears on the storefront but shapes campaigns:
| Metafield | Feed attribute | What it enables |
|---|---|---|
| Material | material | Matches attribute-specific searches |
| Pattern | pattern | Distinguishes similar variants in listings |
| Gender, age group | gender, age_group | Required for apparel in some countries |
| Margin tier (internal) | custom_label_0 | Separate bids for high- and low-margin products |
| Season or launch (internal) | custom_label_1 | Split new arrivals from the core range |
Migrating existing content into metafields
Most stores I work on have specs scattered across descriptions written by different people in different formats. The order matters more than the tooling.
- Export products and study the description HTML. Look for patterns: spec tables, “Material:” lines, repeated care paragraphs.
- Create definitions first, with validation on. Values stored without a definition won’t appear as dynamic sources or filter options until you add one.
- Build shared content before references. Create metaobject entries like size guides, then set each product’s references.
- Extract the values. Consistent HTML can be parsed with a script or spreadsheet formulas. Inconsistent copy suits an AI extraction pass with human review; spot-check every category before importing.
- Load in bulk. The bulk editor handles small catalogs; for thousands of products, use a bulk import app or a script against the Admin API.
- Connect and QA on a duplicate theme before publishing.
- Clean the descriptions last, so information never disappears from the page mid-migration.
Before you call it done:
- Every definition has a clear name, description and owner
- Filter fields are filled across every collection where the filter shows
- Storefront API access is enabled for fields a headless front end reads
- Translations exist for each language your markets use
- Empty-value behavior is checked on every product template
Data modeling and migration is a standard part of my Shopify development work, whether it’s a redesign, a replatform or a store that has outgrown its descriptions.
Get it built
If every redesign or new market means re-editing hundreds of product descriptions, I can model your data, migrate it and connect it to your theme, filters and feeds. Shopify builds and migrations start at $6,000. See pricing or get in touch.