How to see the maximum attachment size limit on Postfix

The default maximum attachment size limit on a new Postfix installation is 10 MB (10240000 bytes). That’s probably a bit too small for most modern use cases.

/etc/postfix/ controls the default size limit. On a new installation or default installation, you might not see the configuration variable which is message_size_limit. To see the setting even if it’s not in the configuration file, use postconf with -p:

postconf -p | grep message_size_limit
message_size_limit = 10240000

To change it to 30 MB, use these commands:

sudo postconf -e 'message_size_limit = 30720000'
sudo postfix reload

You could even go higer. As of around ~2021 Google had a 25 MB limit, and Office 365 had a configurable 1 to 150 MB limit.

Use postconf again to see if the changes worked:

postconf | grep message_size_limit
message_size_limit = 30720000

Making the change via Webmin

Follow the screenshot below to change the message_size_limit via Webmin.

The menu is: Webmin => Servers => Postfix Mail Server => General Resource Control



Share this article

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to Top