How to move customer from one website to another in Magento?

magento, migration, web

Solution

OK, here's just an idea. I've never tried this myself before and this is usually not the way things should be done. So backup your database or setup a test installation where you try this first and follow the below steps:

1) Find out the old website id and the new one where the customer have to be added

2) open your database with a MySQL Client or PhpMyAdmin

3) go to table 'customer_entity' and open the content

4) change one of the customer entries from old website id to new website id

If this works, you could write an sql update that changes all the website ids in that table. You can also check if that customer account (e-mail address) exists in website B or not for each entry. http://dev.mysql.com/doc/refman/5.1/de/update.html

The better way this should be done: Writing a little Magento Module with some code that reads out all the customer data from website A and writes it into website B. But this needs some Magento Development Skills. If you're interested in a professional solution, feel free to contact.

cheers

edit: could make sense to change the store_id value as well

Problem

I have 2 websites set up in Magento, each has one store in it. Each website has its own customer accounts. Now, I need to shutdown one website, and migrate all customer accounts from website A to website B, so that customers from website A's store can login to website B's store. What do I need to do to accomplish this? What to do if a customer has account on both website A's store and Website B's store?

Original source