ErrorMessageSizeExceeded - Failed to Write Mail

Increase Office 365 mailbox size limits to allow large email migration.

Last updated: 2025-01-15 Troubleshooting

Error Message

Migration Error

Failed to write Mail:[Subject] ErrorMessageSizeExceeded

This error occurs when an email exceeds Office 365 size restrictions.

Size Limit Issue

📧
Source Email
75 MB
📏
O365 Limit
35 MB default
Rejected
Too large

Root Cause

Email Exceeds Exchange Web Services Limit

The email being migrated is larger than the maximum send/receive size configured in the target Office 365 mailbox. By default, Office 365 has relatively conservative size limits.

Default Office 365 Limits

Office 365 typically defaults to 35 MB for send/receive size limits. Large emails with attachments from other systems may exceed this limit.

Solution

Increase Mailbox Size Limits Using PowerShell

1

Check Current Settings

First, verify the current size limits for the affected mailbox:

Get-Mailbox user@domain.com | fl mailboxplan,maxsendsize,maxreceivesize
2

Update Tenant-Wide Limits (New Users)

Set limits for new mailboxes (applies to future users only):

Get-MailboxPlan | Set-MailboxPlan -MaxSendSize 150MB -MaxReceiveSize 150MB
3

Update Existing Users

Apply new limits to all existing mailboxes:

Get-Mailbox | Set-Mailbox -MaxReceiveSize 150MB -MaxSendSize 150MB
4

Verify and Retry

Confirm the changes took effect and restart the migration for the affected items.

Post-Migration

After migration completes, you can restore original size limits if desired. Keep in mind that very large emails may cause performance issues for users.

Update Single Mailbox

To update just the affected mailbox instead of all mailboxes:

Set-Mailbox user@domain.com -MaxReceiveSize 150MB -MaxSendSize 150MB

Was this article helpful?

We value your feedback

Help us improve your experience

What would you like to share with us?

Need direct support? Open a ticket