After you have successfully installed Shopware 6 on your server, you can begin migrating your Shopware 5 shop. For this you need the Migration Assistant extension for Shopware 6, which you can get from the Community Store.
It is also necessary to install the extension Migration Assistant in your Shopware 5 Shop from which you want to migrate.
The following description of the migration process refers to the migration assistant from version 13.0.0 of the extension.
In order to migrate your data from Showare 5 to your Shopware 6 shop, you must first create a connection to your existing Shopware 5 shop. You start this in the Shopware 6 Administration under the menu item Settings->Migration.
As long as this connection to your Shopware 5 Shop exists, you can migrate data from the Shopware 5 Shop at any time.
Then click on Create connection to create a new connection.
Name: Here you first enter a unique name for the connection. This is especially necessary if you want to establish a connection to several Shopware 5 Shops.
Please do not use hyphens in the connection name. The free text fields from Shopware 5 are transferred to Shopware 6 as custom fields with the connection name. If a hyphen is present, this ensures that the custom fields are no longer displayed correctly in the storefront.
Profile: Describes the type of your source system. In the standard system, Shopware55 is selected for the migration. However, third-party providers can also work with other profiles.
Gateway: Indicates the type of connection between the two systems. Here you choose API if you want to migrate a remote shop, or Local if the shop you want to migrate is on the same server.
Depending on the interface you chose in the last step, you will now receive one of the following two queries.
API:
API-Key: Here you enter the API key of your Shopware 5 user. If none has been created yet, you can do this in the user administration of Shopware 5.
Username: Enter the username of your Shopware 5 administrator here. This must be the user for who the above API key was assigned for. It is important that this user must be in the "local_admins" group.
Shopdomain: Enter the domain of your main shop here. Be sure to indicate whether the shop uses a secure SSL connection.
Local:
DB-Host: Enter the Host URL of your database here. If the database is installed on the same server, you can also enter localhost here.
DB-Port: Enter the default port of your database here. Usually this is 3306 by default.
DB-User: Gebe hier einen Datenbank Benutzer mit Administrationsrechten an.
DB-Password: Enter a database user with administration rights here.
DB-Name: Here you enter the database name of the database which contains the data of your Shopware 5 installation.
Installation Root: Enter the absolute path to the directory where Shopware 5 was installed.
As part of the migration, some metadata will be truncated as the database dyp will change from mediumtext to varchar(255). These values will therefore be truncated after 255 characters.
The following values are affected:
table | column |
s_article | description |
s_categories | metadescription metakeywords |
After you have entered all the necessary details of your connection, you will be redirected to the migration overview. Here you have an overview of the current connection, can choose which data will be migrated and track your previous migrations.
After you have successfully established the connection, you will automatically be taken to the migration overview. Here you can see which shop system (1) you are currently connected to. For the connection you can also immediately see which system profile and which interface was used, when the last connection check was carried out and when the last migration was carried out with this connection. Click the Edit Connection button (2) to make changes to the current connection. Via the dropdown menu (3) you can create a new connection, delete the access data of the current connection or switch to another created connection. You can also use this drop-down menu to reset the checksums. Using the reload button (4) refreshes the migration overview. This way, the entire page does not need to be reloaded in the browser to get an updated display of the data.
In the data selection you decide which data you want to migrate from your connection to the Shopware 6 Shop. To do this, simply check the corresponding data to be migrated. The list also shows you whether it is shop data or plug-in data and how many data sets are migrated.
The migration now performs a data check. This checks whether data from the old shop can be assigned to the new shop.
If data, such as the standard payment type, could not be assigned correctly, it is necessary to assign it manually. As soon as you have manually assigned all unassigned data, you can continue the migration by clicking the Continue button. If all data could be assigned without problems, manual assignment is no longer necessary. In this case you can continue the migration immediately.
You can view the assignment you have carried out by clicking on "Show processed assignments". It will then be displayed below the manual assignment section.
In the assignments you can check whether the automatically assigned data have been correctly assigned. Here you can also change your allocations later or change the automatic allocations later.
Extensions: Data that can be migrated from third-party plug-ins is displayed in this list as plug-in data.
Some third-party providers may also offer their own migration profile for their extensions data, which must then be used for migration. In this case you will get all information about the migration from the respective provider.
In the History you have the opportunity to view all previous migrations and migration attempts. All information about the migrations will be displayed.
If you use the Admin Worker to process tasks, you must keep the tab in which the migration was started open until the migration is complete; otherwise, the migration may be interrupted. We recommend using the CLI Worker instead of the Admin Worker in the production system.
After you have clicked on Start Migration, the migration is performed in five steps. Data reading, data writing, media download, cleanup and indexing.
In this step, all data from the source shop that is to be migrated is read. Here you can also change your assignments later or change the automatic assignments afterwards.
If it happens that data is not migrated although it has changed, the checksums can be reset. For more information, see the section Perform migration again.
The read data is now written in Shopware 6.
In this step, all media files from the old Shopware 5 installation are downloaded and loaded into Shopware 6 Media Management.
In this step, the written records that were temporarily stored are deleted from the database table swag_migration_data.
During this process, all indexers are triggered again so that the migrated data is also indexed by Shopware.
If you've already taken the steps Data reading, Data writing, Media download, Cleanup and Indexing you can skip this point.
The migration can also be started via the console (CLI) after the data check step.
It is important that you first start the migration normally via the administration and abort it after the data check step.
Then navigate in the console to your Shopware 6 directory. You should now be above the public folder.
Execute the following command:
php bin/console migration:start argument
The argument variable can contain the following values:
basicSettings | Basic settings and categories (SalesChannel installation etc.) Automatically executed when importing other DataSelections. |
customersOrders | All customers, orders and documents. |
media | All media and folders. |
newsletterRecipient | newsletter recipients |
products | All product data and associated entities. Also associated entities from "media". |
productReviews | Product reviews |
promotions | Promotions |
seoUrls | SEO URLs |
customerWishlists | Wishlists |
If you want to abort the migration, you can use the command php bin/console migration:abort. To display the progress, you can use the command php bin/console migration:get-progress.You can also view the progress in the admin, even though you have started the migration via the CLI.
You can repeat the migration as often as you like. During the first migration, all migrated data is given a checksum. Based on this checksum, the migration wizard recognizes whether data needs to be migrated or not. This prevents data from being migrated twice and possibly overwritten.
If you want to perform a complete migration again so that all data in the target system is overwritten, you can reset the checksums. You can do this in the migration overview in the shop system area using the drop-down menu.