In Shopify Admin you add Metafield Definitions one by one with the Add definition button. With Matrixify you can list them in one Excel or CSV file and Import them in one job. Here we will create definitions with choices and pinning, and then edit them in bulk.
Steps in short
- Create a spreadsheet with one row per Metafield Definition and the Owner, Name, Type, Namespace and Key columns.
- Add validation rules in the Validation columns and a number in Pinned Position for the definitions to pin.
- Import the file in the Matrixify app to create the definitions.
- Check the new definitions in Shopify Admin on the Metafields and metaobjects settings page.
- To edit existing definitions, Export them, update the file and Import it back.
1. List Metafield Definitions in a spreadsheet
A Metafield Definition determines where a Metafield is used, its namespace and key, data type, and validation rules. Each Metafield Definition is listed as a separate row in the file.
Create an Excel file with a sheet named Metafield Definitions, or a CSV file with Metafield Definitions in the file name, for example metafield-definitions.csv. Add these columns:
Owner– for exampleProducts,VariantsorCustomers.Name– the name shown in Shopify Admin, for exampleMaterial.Type– for examplesingle_line_text_fieldornumber_integer. See all Metafield types.NamespaceandKey– together, these uniquely identify a Metafield, for examplecustom.material. The namespace groups related Metafields, while the key identifies a specific Metafield. Alternatively, you can use a singleHandlecolumn containing both values separated by a dot, such ascustom.material.
You can also add other columns, for example to set API access or other Shopify options for the definitions. See all Metafield Definitions columns.
Matrixify does not automatically generate Namespace and Key from Name. Make sure each new row contains both columns or a Handle, otherwise the Import will fail for that row.
The Command column is optional. By default, Matrixify uses MERGE to create new Metafield Definitions or update existing ones.
Add Validations to Metafield Definitions
In Shopify Admin, each Metafield Definition has a Validation section that limits what can be entered in the Metafield. In the file, each limit has its own column, such as Validation: Choices or Validation: Min, and the Metafield Definitions documentation lists all of them. Add only the columns for the limits you want to set.
- To limit the Metafield value to a fixed list, for example a Fabric field with Cotton, Linen or Wool, put the values in
Validation: Choices, separated by a comma:Cotton, Linen, Wool. Shopify Admin then shows the definition as aChoice list. You can add choices only to asingle_line_text_fieldorlist.single_line_text_fielddefinition, and they are optional for these types too. A validation list can have up to 128 values. - To allow only values between a lowest and a highest value, put them in
Validation: MinandValidation: Max. For example, anumber_integerdefinition with 1 and 5 accepts only whole numbers from 1 to 5. This is theValue rangein Shopify Admin. Depending on the type, Min and Max can also be a text length, a date, or a weight, volume or dimension with its unit, for example1 kg.
You can find the supported validation limits for each Type in Shopify’s list of validation options.
Pin Metafield Definitions with Pinned Position
Pinned Metafields show automatically on the matching pages in Shopify Admin, for example on the Product page – see pinning Metafield Definitions in the Shopify Help Center.
A number in Pinned Position pins the definition, an empty cell leaves it unpinned. The number does not set the order: in our test Fabric got 1 and Sizes 2, but Shopify Admin lists Sizes first. Change the order of pinned definitions in Shopify Admin.
2. Import to create Metafield Definitions
In the Matrixify app Home upload the file in the Import section with the Add file button. The app reads the sheet as Metafield Definitions and shows its row count. Press Import to start.
When the Import has finished, press Download Import Results. The Import Comment column shows NEW for each created definition, or the reason a row failed.
3. Check new definitions in Shopify Admin
This is it. In Shopify Admin go to Settings -> Metafields and metaobjects and click Products, or the other Owner you imported. The pinned definitions are at the top of the list.
4. Edit Metafield Definitions in bulk
To change existing definitions, Export them, update the file and Import it back. You can also use the file from step 1 and Import it again. In the Matrixify app Home create a new Export by using the New Export button.
Press Select Sheets and select Metafield Definitions.
Click on the Metafield Definitions sheet card to expand it and select these columns:
- from
Basic Columns:ID,Owner,Handle,Name,Pinned Position - from
Validations:Validation: Choices
To Export only specific Metafield Definitions, press Set Filters under the sheet and add the filters you need, for example:
OwnerwithProductsNamespacewithequals to any ofandcustom
Press Export and wait for the job to finish. Then press Download Exported File.
Now you can update the definitions in the file: rename them or add a new value to Validation: Choices, for example Silk. When the file is ready, Import it the same way as in step 2.
The app finds each definition by ID, or by Owner and Handle when there is no ID – the Import Comment then says UPDATE: Found by Handle. The Type and Handle of an existing definition cannot be changed – a different Type fails the row. A different number for an already pinned definition does not move it and only gives a warning.
Good to know
- Each Export or Import job can have up to 10 Metafield Definitions on the Demo plan, 50 on Basic, 500 on Big and any number on Enterprise – see Pricing.
- A row with the namespace and key of a Shopify standard definition, for example
descriptors.subtitle, enables that standard definition instead of creating a custom one. - The same file can have a Products sheet with the Metafield values. The app Imports the definition sheets first, so the values find their new definitions.
What to do next?
- Fill the Metafield values of your Products and other items – How to manage Shopify Metafields.
- Copy the definitions to another store – Copy Shopify Metafield and Metaobject Definitions to Another Store.
- Delete definitions in bulk and see all columns in the Metafield Definitions documentation.
- Contact Matrixify support if you have questions.



