How do I export metafields to a CSV file?

Modified on Sat, 11 May at 9:06 PM

TABLE OF CONTENTS

Intro

In this tutorial, you will learn about data exports and their real-world applications. 

The most common use cases include, but are not limited to:

1) exporting data from one Shopify store to have it imported to another Shopify store;

2) exporting data to a CSV file to have it edited in a spreadsheet editor and imported back to update the data;

3) generating template files for future data import tasks;

4) creating a backup copy of existing metafields.


Accessing the data export menu

Go to the Apps section of your Shopify admin panel (1) and select our app from the list of installed apps (2):


Next, navigate to the Bulk Actions tab of our menu (3) and go to Export (4):


Data filtering system

The data filtering system is the same as that used in the bulk editor (click here to learn more). If you are not familiar with it yet, you should take a short break here and learn more about the filters available in our app. They are a great tool for precise and fast data management, so visiting this link is the time well spent.


Configuring a data export task

Selecting the CSV file format

Before you proceed with a further configuration, you can select the preferred format for the future export file:


Some merchants prefer to manage spreadsheets via editors like Excel, Numbers, or Google Sheets, while others might tend to automate the process with custom tools. Hence, our app supports two different layouts of CSV files:
1) human-friendly "columns";
2) automation-focused "rows" that allow for better data integrity.
The main difference is that when metafields are exported as "columns", each resource (product, collection, etc.) is represented by a single row with separate columns for each metafield, whereas, when exported as "rows" - each metafield is represented by an individual row that contains both the metafield and the parent resource data.


Here you can see the difference the format makes for 30 metafield records:

1) The rows format

2) The columns format

Selecting the data to be exported

Metafields to be exported

If you want to have all metafields exported to a CSV file, you should not apply additional filters. However, if you want only specific metafields to be exported, there are multiple options to make it happen. You can either specify the list of namespace/key combinations to be exported (1) or export all metafields that belong to a certain namespace (2):

Adding standard Shopify attributes to the export file

You can also select from a wide range of standard Shopify attributes to be included in the export file. Yet another great thing is that you can include the first variant data when exporting product-level metafields:


Additional options

Export empty metafields

Use this option to have empty/non-existent metafields represented by placeholder records in the export file. Useful for creating template files or reports on specific metafields.


Export modes

Three export modes are available:

1) Default - metafield values will be exported without any changes;

2) Readable - for complex metafield types like references and lists, an extra column with user-friendly value will be added;

3) Migration - the GIDs (click here to learn more) in reference metafields will be replaced with handles or other secondary identifiers suitable for data migration. Due to the peculiarities of Shopify, the "same" product in two different stores can't have the same ID, but it can have the same handle. This approach allows to preserve relations between entities while exporting metafields from one Shopify store to another.


Downloading the results

Navigate to the History tab of the Bulk Actions menu, find the export task you are interested in, and click on the Results button next to it:


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article