# Magento 1 → 2 Migration Tool

> Full database migration from Magento 1 to Magento 2 — products, customers, orders, CMS, and more

Migrating from Magento 1 to Magento 2 is one of the most complex tasks in the Magento ecosystem. Adobe's official migration tool is notoriously difficult to work with and often fails on real-world databases with custom modifications.

This tool takes a different approach: it maps database structures between Magento 1 and Magento 2 directly, without introducing complex abstraction layers. It supports both full data migration and selective partial imports, and it handles the edge cases that other tools miss — image swatches, customer password migration, URL regeneration, and configurable product relationships.

**GitHub:** [qoliber/m2-m1migration](https://github.com/qoliber/m2-m1migration)

## Installation

```bash
composer require qoliber/module-m1migration
bin/magento setup:upgrade
```

## Supported Data Types

| Data Type | What migrates |
|-----------|--------------|
| **Product attributes** | All attribute types including image swatches, custom options |
| **CMS pages & blocks** | Content, layout, store assignments, URL keys |
| **Store configurations** | All config paths and values, scope-aware |
| **Orders** | Full order history including invoices and credit memos |
| **Customers** | Customer data with password migration (customers can log in with their M1 password) |
| **Newsletter** | Subscriber list with subscription status |
| **URLs** | Full URL regeneration for SEO continuity |
| **Catalog** | Categories, products (Simple and Configurable), inventory |

## Migration Methods

### Full Migration

Complete data transfer between Magento 1 and Magento 2 instances. Best for initial migration when setting up a new M2 installation.

### Partial Import

Selective import of specific entity types. Useful for:
- Migrating orders in batches
- Importing specific CMS blocks or email templates
- Incremental updates during a phased migration

## Architecture

The tool implements two synchronization mechanisms:

- **SyncAbstract** — Handles EAV (Entity-Attribute-Value) table structures, which is how Magento stores most product and customer data
- **TableImportAbstract** — Handles flat table structures (orders, quotes, URL rewrites)

All operations are available as CLI commands for scriptable, repeatable migrations.
