Skip to main content
MultiTEL logo
  • ABOUT
  • RESOURCES
    • Network Map
    • Rate Centers & LATAs
    • CPNI
    • Docs
    • Product Roadmap
  • SOLUTIONS.
    • E911
    • CNAM
    • PBX
    • Colocation
    • Call Routing LRN
    • LATA and Switch Data
    • Global Phone numbers
  • PRICING
  • DEVELOPERS
  • COVERAGE
  • CONTACT
  • LOGIN
  • SIGNUP
  • EN
    • EN
    • ID
    • RO
    • ES
    • PT
    • RU
    • IT
November 12, 2019

Migrating email with ImapSync

This tutorial will explain how you can migrate your existing email accounts to our Hosted Email service.

If you want something easy/simple to do , you can use this online tool, and migrate accounts one by one:

https://i005.lamiral.info/X/

OR

If you are a do-it-yourself kind of person, an easy way to automate migration from your old email service provider to our Hosted Email Service is to use ImapSync.

This can be downloaded here:

https://imapsync.lamiral.info

Start with downloading ImapSync. You can either purchase it from the website above, or grab earlier versions from Ubuntu/Debian repositories.

This can also be downloaded from Github, here:

https://github.com/imapsync/imapsync

Once compiled/installed, generate a list of your users in this format:

[source-username],[source-password],[destination-username],[source-password]

Where [source-username] is the source IMAP username (email address), and [destination-username] is the username (email address) for your destination (IMAP server. There should a single source => destination entry per line. Separate new entries with newlines:

SOURCEUSER1@SOURCEDOMAIN.com,password,DESTINATIONUSER1@DESTINATIONDOMAIN.com,password
SOURCEUSER2@SOURCEDOMAIN.com,password,DESTINATIONUSER2@DESTINATIONDOMAIN.com,password
johndoe@test.com,password,janedoe@newtest.com,password 


Save the file as migration.csv. Then run this command:

{ while IFS=',' read u1 p1 u2 p2; do
./imapsync --host1 [source-hostname] --authmech1 PLAIN --user1 "$u1" --password1 "$p1" --prefix1 INBOX/ --sep1 / \
--host2 [destination-hostname] --authmech2 PLAIN --user2 "$u2" --password2 "$p2" --prefix2 INBOX. --sep2 . ...
done ; } < migrations.csv


Replace [source-hostname] with the hostname/IP of the source server. Replace [destination-hostname] with the hostname/IP of the destination server.

Executing this command will import all emails from the source to the destination accounts.

Please note, this document assumes that the namespace separator of host1 is "/" and host2 is "." . This might be different on your current mail server.

--prefix1 INBOX/ --sep1 /
--prefix2 INBOX. --sep2 .

These are optional, but may be necessary as the mail server strictly uses "." .

Note: When migrating, the order of messages in the inbox will be arranged/displayed by the date the message was last modified (Not necessarily the date the email was received).

Similar Articles

February 09, 2015

Required documents for certain countries

READ MORE
February 09, 2015

STUN Servers

READ MORE
March 05, 2015

What is Toll Fraud

READ MORE
April 14, 2015

Linksys LRT224 recommended settings for VoIP

READ MORE
April 15, 2015

Recommended settings for SonicWall products for SIP protocol

READ MORE
MultiTEL logo
  • COMPANY
  • PRICING
  • DEVELOPERS
  • CONTACT
  • SOLUTIONS
  • E911
  • CNAM
  • PBX
  • Call Routing LRN
  • LATA and Switch Data
  • Global Phone numbers
  • COVERAGE
  • International Numbers
  • Portability
  • Voice and SMS

ANYWHERE, ANYTIME

Hassle-free cost-effective
communications & collaboration solutions

SIGNUP NOW
PCI validation certificate Better Business Bureau Rating A plus rating badge in blue A+ BBB View BBB profile

© 2026. MultiTEL LLC. All rights reserved

Facebook X (formerly Twitter) LinkedIn YouTube
  • Terms of Service
  • Privacy Policy
  • Support
  • Contact