How to Migrate from Magento 1 to Magento 2

Magento 2 was released in July 2015, and since then, the focus and strength of this E-commerce platform shifted from Magento 1 to Magento 2. Magento 2 has a completely different architecture than Magento 1 and a lot of new features! It supports PHP 7, full-page cache by default, and is much faster than Magento 1. With a user-friendly checkout method, improved indexers and database optimizations, Magento 2 proves to be a number one choice for E-commerce store merchants!

Apart from these amazing features, the fact that Magento will end support for Magento 1 on June, 2020, is the reason why it is wise to migrate to Magento 2 asap!

Magento will end the support for Magento 1 and no one would like to be left behind. This is the right time to start planning the process of Magento 2 migration. It is already known that the process, if not handled properly without strategic planning, may ruin the store functionality.

If you are planning to carry out the migration process on your own, for your store, the post is for you! Here’s everything you need to know to migrate from Magento 1 to Magento 2!

But before the actual implementation, please take note of few things that’ll help you to avoid landing yourself into problems such as data loss, or corrupted functionality!

  • Backup your Magento 1 store with all files, folders, and the database.
  • Create a clone of your Magento 1 store. Do not use the live store for Magento migration process.
  • Analyze the store. Keep what you consider necessary and delete the rest.
  • Check the compatibility of current themes, extensions and custom code with Magento 2.
  • Migrate the data from the cloned database of Magento 1 store.
  • Get rid of the outdated and useless data from the database such as logs, recently viewed products, etc.
  • Install a fresh copy of Magento 2 on the same hosting server where your Magento 1 store is located.

Now time for the real action!

It is safe to follow the Official Magento Migration Documentation, according to which, the process is divided into four stages.

  1. Theme Migration
  2. Extension Migration
  3. Customizations Migration
  4. Data Migration

Each step is explained in the simplified manner below!

  1. Theme Migration

    Magento 1 theme can’t be migrated directly to Magento 2. However, you may create a custom theme or install one of them from Magento Marketplace.

  2. Extension Migration

    The Magento 1 extensions won’t be compatible with Magento 2. Install useful Magento 2 extensions for the store. Till date, there are no official tools to migrate extensions from Magento 1 to Magento 2.

  3. Customizations Migration

    There are high chances that your store would be running on custom code. So it is essential that you migrate the custom code to Magento 2 safely.

  4. Data Migration

    The last step includes data migration of customers, orders, products, store configurations, etc. The store data is valuable and can’t be lost at any cost. Hence, you may take the help of  Magento 2 Data Migration Tool. The tool helps to migrate the database of Magento 1 to Magento 2, making it compatible with the new structure.

The process to migrate from Magento 1 to Magento 2 does not stop here! You need to test the Magento 2 store’s functionality thoroughly.

Moving ahead, let’s see the installation and configuration of Magento 2 Data Migration Tool!

Install Magento 2 Data Migration Tool via Composer

Before you start the tool installation, make sure that the version of Magento 2 store and Data Migration Tool match.

For example, if you are using Magento version 2.2.0, you must install the Data Migration Tool version 2.2.0.

If you don’t know the version of your store, navigate to the root directory of Magento 2 via SSH and enter the following command:

Update the location of the Data Migration Tool package in the composer.json file to make it work. For that, run the below two commands:

In the above command, <version> refers to the tool version that is the same as that of your Magento 2 version.

For example, the above commands for Magento version 2.2.0 will look like this:

You’ll need to enter your developer authentication keys. Go to the Magento Marketplace, login, navigate to your profile and click Access Keys under My Products section.

Enter the username, i.e., public key and password, i.e., private key. You may create new keys using Create a New Access Key button.

That’s all for the installation of Data Migration Tool in Magento 2 store.

Configure Magento 2 Data Migration Tool

The following directories will contain mapping and configuration files for the Data Migration Tool.

It contains configuration and scripts for migrating from Magento 1 Open Source platform to Magento 2 Open Source platform.

The above file will contain configuration and scripts for migrating from Magento 1 Open Source platform to Magento 2 Commerce.

The above file will contain configuration and scripts for migrating from Magento 1 Commerce to Magento 2 Commerce.

Before you migrate any settings and data, you must create a config.xml file in the relevant directory. For example, if you are performing data migration from Magento 1 Open Source platform to Magento 2 Open Source platform, navigate to the <Magento 2 root dir>/vendor/magento/data-migration-tool/etc/opensource-to-opensource/<Magento 1.x version> directory and rename config.xml.dist to config.xml.

Next, open config.xml in a code editor and specify the following:

Here, <source> has the database information of Magento 1 and <destination> has the relevant database information of Magento 2. <crypt_key> is mandatory and needs to be filled prior to run. It is the encryption key of Magento 1 store and can be found in the <Magento 1 root dir>/app/etc/local.xml file, within the <key> tag.

Finally, save the config.xml.

Migrate Settings Using Magento 2 Data Migration Tool

Magento 2 Data Migration Tool settings include stores, system configurations such as shipping, payment, tax settings, etc.

According to the Magento Data Migration Order, you should migrate settings first. Navigate to your Magento 2 root directory via SSH terminal and run the following command:

where <path to your config.xml> would be vendor/magento/data-migration-tool/etc/opensource-to-opensource/<Magento 1.x version>/config.xml. I have used –reset argument in the above command which forces the Data Migration Tool to start from the beginning.

The success message is displayed once the settings are over.

Migrate Data Using Magento 2 Data Migration Tool

Data migration from Magento 1 platform to Magento 2 platform includes products, categories, orders, customers, wish lists, ratings, etc.

To migrate data, run the following CLI command:

The tool saves its current progress. If an error occurs, it stops the process and resumes from the last known good state.
The success message is displayed on completion of data migration.

Phew ?

That was all about how to migrate from Magento 1 to Magento 2!
Test the store functionalities and enjoy all that Magento 2 has to offer to benefit your business!

The process is complicated and requires professional attention! One cannot afford any mistake in the migration process as it may result in data loss or improper store functioning. Such a mistake may incur a huge loss in business and so it’s wise to ask for the expert’s advice.

When it comes to Magento 2 migration, we take pride in migrating 200+ stores successfully. If you want professional help with 100% satisfaction, you can always ask for Magento 1 to Magento 2 Migration Service that guarantees Magento 2 migration with zero downtime and no data loss! ?

How to Migrate from Magento 1 to Magento 2 1

5
(based on 25 Reviews)
How to Migrate from Magento 1 to Magento 2

Sanjay Jethva

Sanjay is a co-founder at Meetanshi. He is a Certified Magento Developer who loves creating Magento E-commerce solutions. Owing to his contributions in Magento Forums and posting solutions, he is among the top 50 contributors of the Magento community in 2019. When he is not engrossed with anything related to Magento, he loves to play cricket.

Leave a Reply

Your email address will not be published. Required fields are marked *