I think to have answered this question more than 20 times (live and on socials) but regularly it pops out, so I think that a quick post can help.
Dynamics 365 Business Central (SaaS and on-premises versions) has its own operational limits, limits imposed at platform level to ensure the availability and quality of Business Central services. You can see a list of the operational limits here.
One of the listed operational limits is related to the maximum file size that can be possible to upload on the Dynamics 365 Business Central server: the maximum size of files that can be uploaded to or downloaded from the service is by default = 350 MB.
But what happens sometimes when you upload a large file (for example a 50 MB file) on a Dynamics 365 Business Central on-premises instance? This file size is under the above limit, but you could receive the following error:
Why this?
Because on Dynamics 365 Business Central on-premise there are two settings that you need to check:
- Dynamics 365 Business Central service tier setting
- IIS setting
In Dynamics 365 Business Central on-premises, in the CustomSettings.config file you have the ClientServicesMaxUploadSize setting:
Default is 350 MB but you can change it accordingly to your needs.
But this is not enough to handle large files! The second setting to check is at the IIS level (web server).
To check that, open IIS Manager, select your Dynamics 365 Business Central web server instance and click on Request Filtering:
When the Request Filtering pane displays, from the Actions pane on the right hand side of the screen click Edit Feature Settings. The Edit Request Filtering Settings window displays and here you can change the Maximum allowed content lenght (Bytes), setted as default to 30 MB:
When you change this value, please remember to restart the IIS instance.
Remember also that IIS has a limit of 4 GB (4294967295). Setting the value higher than 4 GB here will not remove that limit.