Step 1: Access Metafield Definitions
- Log in to your Shopify Admin.
- Navigate to Settings > Custom data.
- Under the Custom data section, select Products.
Step 2: Add a New Metafield
- Click “Add definition” to create a new metafield.
- Name your metafield: Give it a descriptive name, like
Product Features
. - Namespace and Key: Use a namespace like
custom
and a key likefeatures
. For example:custom.features
. - Description (optional): Add a description to explain the purpose of the metafield, e.g., “Displays product features on the product page.”
Step 3: Choose Content Type
- Select the type of content you want for the metafield. For a product feature block, consider:
- Single-line text: For a brief feature or headline.
- Multi-line text: For detailed product features or a list.
- List of values: To allow multiple entries like bullet points.
- Rich text: If you want formatted text (bold, italics, etc.).
- Set any validation rules (e.g., character limit or required field) if necessary.
Step 4: Save the Metafield Definition
- Click Save to add the metafield to your product settings.
Step 5: Add Metafield Values to Products
- Go to the Products section in your Shopify Admin.
- Select a product you want to add the metafield value to.
- Scroll down to the Metafields section in the product editor.
- Locate your newly created
Product Features
metafield. - Enter the feature(s) for this product. For example:
- “Durable stainless steel construction”
- “Eco-friendly materials”
- Click Save.
Step 6: Connect Metafield to the Block
- Inside each Product Feature Block input field, link the corresponding metafield by entering the namespace and key like
"{{ product.metafields.custom.location }}"