MS-Graph Attachment limits

Rajat M Jain 41 Reputation points
2021-03-30T06:47:38.69+00:00

The attachment limit of 3MB applies to the attachment content or the base64 encoded attachment contents?
In other words, is it allowed to POST an attachment to a message in Microsoft Graph when the base 64 encoded contents are more than 3MB but the actual file is less than 3MB?

Microsoft Graph Mail API
Microsoft Graph Mail API
A Microsoft API that supports accessing data in users' primary mailboxes and in shared mailboxes.
686 questions
No comments
{count} votes

Accepted answer
  1. Glen Scales 3,871 Reputation points MVP
    2021-03-30T23:50:47.82+00:00

    The actual upload limit is 4mb which is because the largest value a JSON string can be is 4mb, the guidance around 3MB is because Base64 encoding bloats a message from its binary size by up to 33% so a file size below 3MB should mean once encoded your not going to have a problem. But you always need to go off the encoded size rather the binary size.

    No comments

0 additional answers

Sort by: Most helpful