Merchants Answered
Operations answers for working Shopify merchants

Shopify metafields explained

The field Shopify never shipped

Every Shopify store has the same fixed fields: title, price, description, weight. But a candle needs a burn time, a sofa needs dimensions, a skincare product needs an ingredients list, and a food product needs care instructions. There is no built-in box for any of that, and stuffing it into the description means it cannot be filtered, styled, or reused.

A metafield is the fix. It is a named piece of custom data attached to a Shopify resource, addressed by a namespace and a key, like custom.burn_time. The definition holds the name, the type, and the validation rules, and it applies to every product. Each product then stores its own value. That is the whole system, and it is built into Shopify admin, so no app is needed to start.

Three parts, and the type matters most

Every metafield has three parts. A definition, which is the schema that names the field and sets what it accepts. A namespace and key, which is its unique identifier, written with a period, like custom.care_instructions. And a value, the data itself, entered per product.

The type is the choice that matters most, because it is a real type system, not a free-text box. Single line text, rich text, integer, decimal, date, dimension, weight, volume, rating, color, URL, JSON, plus references to files, products, pages, and metaobjects. Switch a definition between incompatible types later and the existing values become invalid until fixed, so pick the type before filling in a hundred products.

The limit, and the trap

Merchants can create up to 256 metafield definitions per resource type, and each installed app gets its own 256 per resource type. That is generous, but it is a real ceiling, and stores that create a definition per product instead of per attribute hit it.

The trap is the naming one. If your metafield key is size, first, or last, dot notation in Liquid silently breaks, because those are Liquid filter names. Use a different key, or the value comes back wrong with no error. A page that warns about that saves a developer an afternoon.

Showing it on the storefront

Creating the definition is half the job. The data exists and the storefront still shows nothing, which is the step most guides skip. On an Online Store 2.0 theme, open the theme editor, add a text or rich-text block to the product template, click the dynamic source icon, and pick the metafield. One template then shows each product's own care guide, ingredients, or size chart, with no code at all.

Related reading

If this topic is useful, these earlier guides go deeper on connected questions: Shopify duties at checkout explained, Shopify local delivery explained, and Shopify draft orders explained.

Frequently asked questions

What is a Shopify metafield?

A custom field you add to a product, collection, customer, order, or other resource to store data Shopify has no built-in field for, like care instructions, ingredients, or a size chart. Every metafield has a namespace and key, a type, and a value entered per record.

What is the difference between a metafield and a metaobject?

A metafield adds one field to something that already exists, like a product. A metaobject is a whole custom record type you invent, like a size chart with several fields, which products point at through a reference metafield.

How many metafields can a Shopify store have?

Up to 256 metafield definitions per resource type for merchants, with each installed app getting its own 256 per resource type. Standard definitions do not count toward that limit unless Shopify says otherwise.

Why is my metafield not showing on the storefront?

Because creating it only stores the data. You still have to connect it in the theme editor using a dynamic source, print it in theme code, or let an app display it. On an Online Store 2.0 theme, connect the metafield to a section or block setting and the template will show each product's own value.