Magento 2 product import – category mapping

- E-Commerce, Magento 2

When migrating from different ecommerce platforms to Magento 2 you may find yourself in need to adjust category paths for products. Doing it manually is a tedious and troublesome task.

In this article we will talk about how can one map category paths during Magento 2 import procedure and the tools required.

'

What is category mapping? When mapping categories – you are specifying an existing category path and the new path you want it to be converted to. With native Magento 2 import it is not possible, however there is always an alternative.

The alternative is Improved Import and Export extension for Magento 2 developed by FireBear Studio. With the extension you can pretty much migrate from any platform thanks to available mapping options which include:

  • Product mapping;
  • Category mapping;
  • Import table mapping (separators).

In this article, however, we will talk about how to map categories during product import.

How it works

If you are familiar with Improved Import and Export extension you should know that the extension uses ‘jobs’ – a set of rules that are available for every import/export instance. If you are new to the extension you may first want to refer to the extension product page for more information.

The recent release has added a new settings section to the jobs called ‘Map Categories’.

The section is extremely simple and is represented by the following elements:

  • ‘Load Categories from Import File’ button – use this button to upload category paths from the import table;
  • Mapping grid – use this grid to map category paths from the import table with appropriate category paths at your Magento 2 store;
  • ‘New Category’ button – use this button to create new category at your Magento 2 store.

As you can see the mapping tools are pretty simple. In the next chapter we will talk about how to map categories step by step.

Mapping categories

As mentioned previously we will be creating an import job using Improved Import and Export extension. The whole category mapping process is done via import jobs.

Step 1: create an import job and upload import table

For convenience purposes we will omit this step. A thorough instruction on how to create an import job for product import can be found in the Improved Import and Export extension manual.

Step 2: upload categories

Now that you are done with the general job settings and have uploaded your product import table it is high time to scroll down to the Categories Mapping section.

To upload the categories list from the import table click ‘Load Categories from Import File’ button.

Once the extension done loading categories from the import table you will get a success message. Now you can proceed mapping categories.

Step 3: map categories

The category mapping process is pretty simple. In the Import category path of the mapping grid you select the category from the import file. And in the New category path column you are selecting category path at your Magento 2.

As you can see from the GIF above the process takes not much time and is backed up by visual representation of the full category tree with options search field.

Step 4 (optional): add new categories

If you find that your store is missing some of the categories you don’t have to go to a separate page to create them. Instead you can create new categories right from the mapping grid. To do this click ‘New Category’ button.

In the popover screen you will be suggested to specify the new category name and select parent category. Once done click ‘Create Category’ button. You can add any number of categories this way.

Step 5: run the import job

When you are done with mapping categories it is time to run the job. To do this click ‘Save & Run’ button at the top right corner of the screen.

In the popover screen click ‘Run’ button to actually run the job.

The extension will display a job log where you can check how the import went. The log will also display any errors that may have occurred during import.

That’s it for Magento 2 category mapping. If you want further instructions on how to use Improved Import and Export extension – visit the extension product page here.

'