How to Use Dynamic Sources and Metafields in Maison

In some cases, you may want to display different product information on a case-by-case basis. The Maison theme supports SHOPLINE dynamic sources, allowing you to connect product metafields to compatible theme sections and blocks.

This guide explains how to create a Product metafield, assign values to products, and connect that metafield to a block using Add dynamic source.

STEPS:

1. Understanding Dynamic Sources and Metafields

Metafields allow you to store custom information for SHOPLINE resources, such as products.

Dynamic sources allow you to connect that metafield data directly to compatible theme settings in the Theme Editor.

Example use case:

Product Product characteristics metafield
Chair A Solid oak frame with a natural finish.
Chair B Powder-coated steel frame with a matte finish.
Chair C Upholstered seat with a solid walnut base.

Instead of writing product-specific content manually inside the Theme Editor, you can create a metafield once and assign different values to each product.

Recommended use cases:

Use case Example content
Product characteristics Material, texture, construction, or key features
Ingredients Product ingredients or formula details
Materials and care Fabric, cleaning instructions, or care guide
Delivery note Product-specific shipping or availability note
Size guide note Extra sizing information for a specific product
Technical specifications Dimensions, weight, compatibility, or product specs
2. Creating a New Product Metafield

In this example, we will create a Product metafield called Product characteristics.

  • From your SHOPLINE admin, go to Settings > Customize data.
  • Under Metafields, select Product.
    docs__maison__how-to-use-dynamic-sources-and-metafields-in-maison__01.webp
  • Click Add fields.
  • Enter the metafield name.
docs__maison__how-to-use-dynamic-sources-and-metafields-in-maison__02.webp

Example:

Product characteristics
  • Configure the Namespace and key.

For this example, use:

custom.product_characteristics
  • Optional: Add a description.

Example:

Add key information to describe the product.
  • Select a compatible data type.

For this example, use a text field that can contain the required product information.

  • Use a single value.
  • Configure any available validation rules if needed.
  • Click Add or Save.

Recommended setup:

Field Value
Name Product characteristics
Namespace and key custom.product_characteristics
Type Text
Value type Single value
3. Adding Metafield Values to Products

After creating the metafield, you can add a different value for each product.

  • From your SHOPLINE admin, go to Products.
  • Open the product you want to edit.
  • Scroll down to the Customize data area.
  • Find the Product characteristics metafield.
  • Add the product-specific information.

Example:

Solid oak frame with a natural finish and reinforced joinery.
  • Click Update or Save.
docs__maison__how-to-use-dynamic-sources-and-metafields-in-maison__03.webp

Repeat this step for every product that needs its own custom information.

For example:

Product Product characteristics
Chair A Solid oak frame with a natural finish.
Chair B Powder-coated steel frame with a matte finish.
Chair C Upholstered seat with a solid walnut base.

Each product can now use the same Maison Product template while displaying its own metafield value.

4. Connecting the Metafield to a Theme Block

After adding metafield values to products, you can connect the metafield to a compatible Maison setting.

In this example, we will connect the Product characteristics metafield to the Content field of an Accordion row on the Product page.

  • Open the Maison theme editor.
  • Open the required Product template.
  • Open the main Product section.
  • Expand Product information.
  • Add an Accordion block if one is not already available.
  • Inside the Accordion, add an Accordion row.
  • Drag the block to the desired position.
  • In the Accordion row settings, choose an icon if needed.
  • Enter a title.

Example title:

Product characteristics
  • In the Content field, remove any default text if needed.
  • Click the Add dynamic source icon beside the Content setting.
  • Select Product characteristics from the available dynamic sources.
  • Confirm the connection.
  • Click Save.
docs__maison__how-to-use-dynamic-sources-and-metafields-in-maison__04.webp

The metafield content will now be displayed dynamically based on the current product.

docs__maison__how-to-use-dynamic-sources-and-metafields-in-maison__05.webp
5. Previewing the Result

After connecting the metafield to the Accordion row, preview the Product page.

For example, Chair A can display:

Solid oak frame with a natural finish.

If you open Chair B, the same Accordion row can automatically display:

Powder-coated steel frame with a matte finish.

The Product template and Accordion row remain the same. Only the value changes according to the metafield assigned to the current product.

This means one Product template can display different content for each product without requiring a separate template for every product.

6. Understanding Add Dynamic Source

To know whether a Maison setting can connect to dynamic data, look for the Add dynamic source icon beside the setting in the Theme Editor.

Dynamic sources can appear on compatible settings such as:

  • Text
  • Rich text
  • Image
  • URL
  • Product
  • Page
  • Other supported section or block settings

Availability depends on:

  • The current page or template context
  • The resource being previewed
  • The theme setting type
  • The metafield data type

SHOPLINE filters the available dynamic sources so that only compatible data is shown.

For example:

Maison setting Example compatible dynamic source
Text Text or number metafield
Rich text / Content Compatible text metafield
Image Image/file metafield
URL URL metafield
Product Product reference metafield
Page Page reference metafield

If a setting does not show the Add dynamic source icon, that setting may not support dynamic sources.

If a metafield exists but does not appear in the list, its data type may not be compatible with that setting.

7. Recommended Use Cases

You can use dynamic sources and metafields for many product-specific details.

Use case Suggested metafield type
Product characteristics Text
Materials and care Text
Ingredients Text
Size guide note Text or compatible page reference
Delivery estimate Single-line text
Product badges Compatible text data
Technical specifications Text or number
Download file File
Custom image File / image
Related content Compatible reference metafield
Product-specific URL URL

Recommended workflow:

  • Create the Product metafield.
  • Add values to the relevant products.
  • Connect the metafield to a compatible Maison setting using Add dynamic source.
  • Preview different products to confirm that each product displays its own value.

Dynamic sources are especially useful when many products share one Product template but require different content in the same location.

8. Notes and Limitations

Please note the following behavior:

  • A Product metafield must be created before you can assign custom values to products.
  • Each product needs its own metafield value if you want different information to appear for each product.
  • A dynamic source can only be connected to compatible theme settings.
  • If a setting does not show the Add dynamic source icon, that setting may not support dynamic sources.
  • SHOPLINE only shows dynamic sources whose data type is compatible with the selected setting.
  • If a metafield value is empty for a product, the connected setting may display no content.
  • Product metafields are stored in SHOPLINE, not inside the Maison theme.
  • Updating the Maison theme does not require you to recreate the Product metafield definitions stored in your SHOPLINE admin.
  • Changing or removing a dynamic-source connection in the Theme Editor does not delete the metafield itself or its saved Product values.
  • Dynamic-source availability can vary depending on the page context and setting type.

To replace an existing dynamic source:

  • Open the connected setting.
  • Click the dynamic source control.
  • Choose another compatible source.
  • Save the theme.

To remove the connection:

  • Open the connected setting.
  • Remove or delete the dynamic source connection.
  • Enter static content or connect another source if needed.

Troubleshooting

If the dynamic source or metafield content does not display correctly, check the following:

  • Make sure the metafield has been created under Settings > Customize data > Product.
  • Make sure the product has a value assigned to the metafield.
  • Make sure you saved or updated the product after entering the metafield value.
  • Make sure the Maison setting supports dynamic sources.
  • Look for the Add dynamic source icon beside the setting.
  • Make sure the correct metafield is selected from the dynamic source list.
  • If the metafield does not appear in the list, check whether its data type is compatible with the selected setting.
  • If the connected content does not appear, check whether the current product's metafield value is empty.
  • Make sure you are previewing the correct Product template and product.
  • If different products show the same static text, check whether the setting is actually connected to the dynamic source rather than containing manually entered content.
  • Save the theme after changing the dynamic source connection.
  • Test several products that use the same template.

Need Further Assistance

If you encounter any issues or need additional help with your Maison theme, please reach out to our support team via our Ticket System for assistance within 8 hours.