I am migrating my current self hosted IMAP mail server (hMailServer) to Google Apps.

I managed to move an account's "sent" folder to Gmail using Thunderbird drag and drop, and while it seems to keep most of the data correctly (date etc), I have 2 problems:

  • Some mails do not keep special characters charsets correctly, i.e. ç - they are shown correctly in thunderbird on the source server AND the destination server, but webmail (Gmail) shows them in a different charset, apparently

  • Some of the sent mails are listed as to "me", as if I sent the mail was sent to myself, even if that is not the case, again, this is a problem only when seeing the it in Gmail.

I suppose these problems might be related to incorrectly set headers in the original emails.
What could I try to change to fix these problems?

What application I could use to perform the migration without the above problems?

  • This has been moved, but I believe it belongs to serverfault as mail servers/migrations are not really related to web applications
    – Razor
    Commented Jul 15, 2011 at 22:53
  • 1
    However, you're migration to Google Apps which is a web application. Also the problem you are experiencing seem to be specific to Google App. Flag the original question as well otherwise the Sever Fault mods won't know you are disputing the migration.
    – ChrisF
    Commented Jul 15, 2011 at 23:13
  • 1
    I did a similar thing a few years ago. For me the main problem was the date that I moved the mails in appeared as the date the mails were sent (until you opened a thread, where it displayed OK). Never found a way to get around that...
    – x3ja
    Commented Jul 16, 2011 at 2:47

1 Answer 1


Use IMAPsync. It's exactly what you're looking for. I successfully used it a few years ago. I don't know for sure about the special characters issue, since I don't have any labels with special characters, but the other issues you brought up work flawlessly. I ran IMAPsync on an underpowered GUI-less virtual server that the company I was leaving was gracious enough to let me borrow for a day or two, and successfully migrated all my mail off the company server. (We parted on very good terms.)

Anyway, I'm not sure exactly which script I used to get the job done (I may have written my own), but both of these seem like promising candidates:

In 2022 IMAPsync is still active and has an easy web interface (the web version has a limit up to 3GB for mailbox).

  • IMAPsync rocks!, and it's almost 21 years old!! ~~2001/07/29~~ Mad props to its author Gilles Lamiral, the thing just works.
    – brasofilo
    Commented May 20, 2022 at 1:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.