- Poll: How reliable are ChatGPT and Bing Chat? - Tue, May 23 2023
- Pip install Boto3 - Thu, Mar 24 2022
- Install Boto3 (AWS SDK for Python) in Visual Studio Code (VS Code) on Windows - Wed, Feb 23 2022
Yesterday, I tried sending a little ZIP file (110MB) with Outlook 2016 from my Office 365 account. After a couple of seconds, Outlook stopped sending, without an error message, and moved my email to the Draft folder. After repeating the procedure, it occurred to me that my little ZIP file exceeded the maximum message size in Office 365.
To find the setting in the Office 365 admin center is not easy and ends in a click orgy. Most guides you find on the web are outdated because Microsoft keeps changing the web interface frequently. Thus, using PowerShell is usually the better option.
Changing message size restriction in the admin center
For the sake of completeness, below you'll find the current click path for accessing the message size dialog. After you login, you should arrive at Office 365 Home. Next, stretch your forefinger and start clicking:
Admin > Users > Active Users > Select User > Mail Settings > More Settings > Edit Exchange Properties > Mailbox Features > Message Size Restrictions > View Details > Change Sent and Received
If Microsoft didn't change the web interface, you should now have the message size restrictions dialog on your screen:
As mentioned above, the default setting is 35MB. The maximum you can set for sent and received messages is 150MB (153600KB). This is not much considering users may want to send videos as an attachment or, as in my case, a couple of PDF files.
Setting the maximum attachment size with PowerShell
Don't think that PowerShell gives you more power. Of course, the limits are just the same.
First you have to establish a remote PowerShell connection with Office 365:
$Cred = Get-Credential $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://ps.outlook.com/powershell/ -Credential $Cred -Authentication Basic -AllowRedirection Import-PSSession $Session
The first command asks you for the credentials that allow access to the user's mailbox. You can check the current mailbox size restrictions settings with the next command:
Get-Mailbox -Identity "UserName@YourDomain.com" | fl maxsendsize,maxreceivesize
Finally, you can change the maximum receive and maximum send size:
Set-Mailbox -Identity "UserName@YourDomain.com" -MaxReceiveSize 150MB -MaxSendSize 150MB
Notice that PowerShell won't tell you if the command succeeded. However, if you think your user should be allowed to send or receive bigger attachments, PowerShell will complain:
The operation on mailbox "michael" failed because it's out of the current user's write scope. The value of property 'MaxReceiveSize' cannot exceed the limit of 150 MB.
MaxReceiveSize cannot exceed the limit of 150 MB
Conclusion
If you use PowerShell to change the message size limit, you can be sure that the commands above will work in the foreseeable future, and of course, if you must change several mailboxes, you will be faster with a quick script.
Now, before you free yourself or your favorite user from message size restriction, look what "undeliverable message" I received after I finally succeeded at sending my little email:
Your message wasn't delivered to anyone because it's too large. The limit is 35 MB. Your message is 110 MB.
And this what I found in the mail header:
Remote Server returned '550 5.2.11 RESOLVER.RST.SendSizeLimit.Sender; message too large for this sender'
Obviously, the recipient's mailbox suffers from the same limits. Thus, it might make sense to modify the maximum size for receiving emails. That way, external emailsarriving at Office 365 won't be rejected. However, currently, sending messages that are larger than 35 MB probably doesn't make much sense because most mailboxes have similar restrictions. So much for unlimited resources in the cloud.
Notice that if you want to change the default maximum send and receive sizes for new mailboxes, you have to modify your default mailbox plan.
Get-mailbox returns “The term ‘get-mailbox’ is not recognized…” Is there something else required to make this work?
I guess something went wrong with your implicit remoting session. Did you follow the procedure under Setting the maximum attachment size with PowerShell?
Hi,
To add to this, full script to run this across an org:
$user = Get-Credential
$session = New-pssession -configurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $user -Authentication Basic -AllowRedirection
import-pssession $session -DisableNameChecking
$users = get-mailbox -identity * | select-object alias, maxsendsize, maxreceivesize
foreach ($user in $users) {set-mailbox -identity $user.alias -MaxSendSize "150 MB" -MaxReceiveSize "150 MB"}
Thank you,
Dennis Vlasikov
This will work on the full org:
Get-Mailbox | Set-Mailbox -MaxSendSize "25 MB" -MaxReceiveSize "25MB"
“Obviously, the recipient’s mailbox suffers from the same limits.”
This is not the recipient’s mailbox that’s returning this message. It’s actually the sender’s.
I am not convinced. 550 is an SMTP error and it means the remote server, that is, the server of the recipient, rejected the message. The fact that the sender is mentioned is because the recipient’s server size limits might depend on the type of the sender (for instance, internal or external). However, error messages in a Microsoft environment are often misleading. So if you have evidence other than the mentioning of the sender, I will take a closer look.
I recommend testing this out using lower limits and smaller file sizes. I also recommend testing by sending to a non-Outlook domain.
I went through this today, and partly used this site as a resource. I also realized through testing (by sending to a Gmail account, with a receiving limit of 25MB) that the response was being generated by Outlook.
I recommend lower limits because OWA has limitations on sizes documented by Microsoft and referenced in another comment.
As an example, if you’re sending a ~42 MB file, and using OWA Outlook, then the limit needs to be more like 60MB (not that it’s the correct percentage, only that I know making a similar change resulted in success).
My testing recommendation would be to send a file to a Gmail account that you know is less than the Outlook limitation but greater than the Gmail limitation. If you still get the 35MB response, then you know it’s Outlook and not Gmail.
I can’t test this anymore because I dumped Microsoft 365 / Outlook long ago. Microsoft’s products are just too unreliable. I had countless discussions with their support. They often would admit that a serious bug exists, but no fix was delivered for months, sometimes years. Email just had to work. If you don’t want to waste your time with wondering why this or that is not working as expected, do yourself and your organization a favor and “upgrade” to Google Workspace. You also need to get rid of Outlook because with every new update you get countless new bugs. It is hard for me to say this because I have been using Outlook and Exchange from the very beginning when they were first released.
https://www.microsoft.com/en-us/microsoft-365/blog/2015/04/15/office-365-now-supports-larger-email-messages-up-to-150-mb/
“OWA, however, restricts the size of the message you can send to 25 percent less than the configured allowed maximum send size.”
I don’t know if the above is relevant (especially considering that 110 MB is right at the edge of 25% of 150 MB), but I tested this out myself and had to increase my limit because the file I was testing with was within that margin.
The “remote server” part of the response if probably throwing you off, but the important part to focus on is that it’s indicating that the message is too large for the sender and not the recipient. Typically, if the recipient rejects the message, you’ll get:
“Your message wasn’t delivered because the recipient’s email provider rejected it.”