I made a hard decision last week. For a variety of reasons (some health-related), I sold my iPhone.

Of course I backed it up beforehand, but I forgot to sync my contacts. Having never actually bothered to merge my MacBook Pro and iPhone contacts, and having already passed on the phone, there was only one place to go to find my contacts and re-integrate them.

The backup files for the iPhones are a compilation of numerous databases named with codes, and require a special utility to be able to read them. (This is, of course, assuming you don’t have yours encrypted.) I found two utilities that helped me with this. One was a paid app ($19.95) and supported exporting contacts. However, I was wary about how they would come out, and didn’t want to pay 20 bucks for something I couldn’t rely on.

With more Googling, I discovered iPhone Backup Extractor, a free piece of software. After much browsing through my other software for “Address Book,” I realized that unlike the Mac, the contacts were stored in the “phone” software. (Otherwise known as “iPhone OS Files” in iPBE.) Unfortunately, it extracts the actual iPhone files. This means that I got the database for the contacts, not the actual vCards.

The databases are in SQL, so I downloaded “SQLite Database Browser 1.3.” I proceeded to sift through the databases and found the contact names and the phone numbers/email addresses split between two databases, linked with a reference number. This meant I had to go back and forth to gather the information I needed, and it was very time consuming. I ended up borrowing a friend’s first generation iPhone, restoring the backup to it, then syncing it with my computer.

The moral? I suggest syncing your contacts to your Mac’s Address Book before your phone gets lost, stolen, broken, or sold. It’s a real disappointment to lose all of your phone numbers!