Functions Request Body Limit - App setting not working

hawthorne91 230 Reputation points
2024-12-19T21:16:10.0166667+00:00

Hello, currently I have an API that takes in POST requests containing files, and uploads them to my Azure Blob Storage account. The issue is that when the files are bigger than 100MB, then the files do not upload.

I am aware that by default the limit to a request is 100MB. I found this post (https://learn.microsoft.com/en-us/answers/questions/1846216/confused-http-request-size-limit-of-100-mb-for-azu) stating that you can increase the limit of the request size by configuring the Functions_Request_Body_Size_Limit in the app settings, however when I set this value in my app settings to higher than 100MB, it still does not allow me to upload the file. For reference, the file I am trying to upload is around 101MB, and my function app is Consumption-based. Can anyone provide me guidance on how to proceed? Thank you.

Update: I upgraded to the Function Premium Plan type, however it still isn't working.

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,249 questions
Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
3,002 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Khadeer Ali 1,400 Reputation points Microsoft Vendor
    2024-12-19T23:41:27.15+00:00

    @hawthorne91

    Welcome to the Microsoft Q&A Platform!

    Thank you for reaching out about your file upload scenario. We understand this can be frustrating. While Azure Functions are great for many tasks, they're not ideally suited for very large file uploads (especially those over 100MB). This is due to limitations in request size, memory usage, and potential timeouts. Even adjusting settings like FUNCTIONS_REQUEST_BODY_SIZE_LIMIT doesn't fully resolve these challenges for larger files.

    Given these challenges, could you try alternative solutions which is already mentioned in the thread you have gone through such as Azure Blob Storage direct uploads, which are specifically designed for managing large files efficiently or Chunked Uploads, Break the file into smaller chunks (e.g., <100MB) and upload them sequentially or in parallel. The Function can reassemble the chunks in Blob Storage.

    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.