I decided to export all the contacts I have in Evolution today and import them into Gmail. I wondered if it would be hard to do (or even possible) and luckily I discovered it was a piece of cake. I’ll call it a 3-step process.
This step is super-simple. Open terminal and paste the following command:
evolution-addressbook-export --format=csv > evolution.contacts.csv
You now have a .csv file (spreadsheet) with all your contacts in it, located in your home folder.
Open the evolution.contacts.csv file in OpenOffice or whatever spreadsheet program you use. I deleted any rows that I didn’t want to keep, and any columns that weren’t being used. I ended up with just a First Name, Last Name, and Email_1, Email_2 and Email_3 column, but you may choose to keep mailing addresses and phone numbers if you have data in those columns. I also renamed the first name and last name columns from given_name and family_name to First Name and Last Name. Gmail is very flexible about column names so the defaults might work, but I was certain that First Name and Last Name would be recognized by Gmail, so I just went with those. Once you’ve cleaned up the file, save it.
In the left sidebar of Gmail, click on Contacts. Once the Contacts page opens, click on Import in the upper right corner. Click the Browse button, choose the file you just saved from your home folder, and click on Import. Gmail will tell you if it deletes any duplicates or merges any together, and will let you know that how many it successfully imported.
That’s it! All done.