How to migrate from Gmail or Google Workspace to shipmail
This guide walks through moving your email from Gmail or Google Workspace to shipmail. It covers DNS changes, mailbox creation, historical email migration, and the most common mistakes people make during the switch.
Pre-migration checklist
Complete these steps before starting the migration.
- List all email addresses you currently use on your domain in Gmail or Google Workspace.
- Note any email forwarding rules, filters, or aliases you want to recreate.
- Check which services send email from your domain (newsletters, transactional email, etc.) so you can update their SPF/DKIM records.
- Export your contacts from Google Contacts if you want to import them into your new mailboxes.
- Decide whether you need to migrate historical email or start fresh.
- Lower the TTL on your domain's MX record to 300 seconds (5 minutes) at least 24 hours before the migration. This speeds up the DNS cutover.
Migration steps
1. Add your domain to shipmail
- Go to the Domains page in your dashboard and click Add domain.
- Enter the domain you currently use with Gmail or Google Workspace.
- shipmail will show the required DNS records (MX, SPF, DKIM). Do not add them yet.
2. Create your mailboxes
- Go to the Mailboxes page and create mailboxes for each address you want to migrate.
- Use the same local parts you had in Gmail (e.g., if you used hello@example.com in Gmail, create a hello mailbox on example.com).
- Set passwords for each mailbox. These are the credentials you will use in your email client.
3. Migrate historical email (optional)
- If you want to bring your existing email over, use an IMAP migration tool. See the IMAP migration section below for details.
- Do this before the DNS cutover so your historical email is already in shipmail when new email starts arriving.
4. Update DNS records
- This is the cutover step. Once you change DNS, new email will be delivered to shipmail instead of Gmail.
- Replace your existing MX record with: 10 mx1.shipmail.to
- Replace your existing SPF record with: v=spf1 include:spf.shipmail.to -all
- If you have other services that also send email from your domain, merge their SPF includes into one record.
- Add the DKIM TXT record shown in your shipmail dashboard.
- Update your DMARC record. If you do not have one, add: v=DMARC1; p=reject
- If other services still send mail from your domain during the migration, use ShipMail's custom DMARC mode and publish your own temporary policy until everything is aligned.
5. Verify the domain
- shipmail will automatically detect the DNS changes and verify your domain.
- Once verified, new incoming email will be delivered to your shipmail mailboxes.
- Send a test email from an external address to confirm delivery.
6. Update email clients
- Update your email client settings to point to shipmail instead of Gmail.
- IMAP: mx1.shipmail.to, port 993, SSL/TLS.
- SMTP: mx1.shipmail.to, port 465, SSL/TLS.
- Username: your full email address. Password: the mailbox password you set in step 2.
7. Tighten DMARC policy
- If you used a temporary custom DMARC policy during migration, tighten it once every sender is passing SPF or DKIM alignment.
- Move from p=none to p=quarantine first if you still want a gradual rollout.
- Finish on p=reject for full protection.
IMAP migration for historical email
To migrate historical email from Gmail to shipmail, you need an IMAP migration tool that connects to both accounts and copies messages over.
imapsync
Open-source command-line tool. Works on Linux, macOS, and Windows. The most reliable option for large mailboxes.
imapsync \
--host1 imap.gmail.com --port1 993 --ssl1 \
--user1 you@example.com --password1 "GMAIL_APP_PASSWORD" \
--host2 mx1.shipmail.to --port2 993 --ssl2 \
--user2 you@example.com --password2 "SHIPMAIL_PASSWORD"Preparing Gmail for IMAP migration
- Enable IMAP in Gmail: Settings > See all settings > Forwarding and POP/IMAP > Enable IMAP.
- Generate an App Password: Google Account > Security > 2-Step Verification > App passwords. Use this as the Gmail password in the migration tool.
- If you use Google Workspace, your admin may need to enable IMAP access and allow less secure apps or app passwords.
Common pitfalls
Forgetting to lower TTL before cutover
If your MX record has a 24-hour TTL, some servers will keep delivering to Gmail for up to 24 hours after you change it. Lower the TTL to 300 seconds at least a day before the migration.
Not merging SPF records
If you keep Google's SPF include alongside shipmail's, merge them into one record. Two separate SPF records cause both to fail.
Gmail forwarding creating loops
If you set up forwarding in Gmail to send email to your new shipmail address, and your MX records already point to shipmail, the forwarding is unnecessary and can create loops. Remove Gmail forwarding after the DNS cutover.
Missing Google Workspace services
Changing MX records only affects email. Google Calendar, Drive, Docs, and other Workspace services continue to work with your Google account. You do not need to migrate those.
App passwords vs. regular passwords
Gmail requires app passwords for IMAP access when 2-Step Verification is enabled. A regular Gmail password will not work with IMAP migration tools.
Frequently asked questions
Will I lose any email during the migration?
If you lower the MX record TTL in advance and migrate during a low-traffic period, the risk is minimal. During the DNS propagation window (typically a few minutes with a low TTL), some email may still be delivered to Gmail. Check both inboxes for a day after the cutover.
Can I keep Gmail as a backup and forward email to shipmail?
This is not recommended. Once your MX records point to shipmail, email goes directly to shipmail. Keeping Gmail forwarding active after the cutover creates unnecessary complexity and potential loops.
How long does the IMAP migration take?
It depends on the size of your mailbox. A few thousand emails typically migrate in under an hour. Large mailboxes (tens of thousands of emails) may take several hours. imapsync handles interruptions gracefully and can resume where it left off.
Do I need to migrate all email, or can I start fresh?
You can start fresh. Just skip step 3 (IMAP migration) and only set up DNS and mailboxes. Historical email will remain in your Gmail account as long as you keep it active.
What about email sent to my old @gmail.com address?
If you used a custom domain with Google Workspace, the migration covers that domain. If you also used a @gmail.com address, that address stays with Google. You can set up forwarding from the @gmail.com address to your new shipmail address.