Web App Max Upload Size

Marcos Feliciano 1 Reputation point
2020-10-02T15:45:56.477+00:00

Hi folks,

I installed WordPress with MySQL in App, and got 50MB as max upload file size, tried many solutions found even here on Q&A, MSDN and so on, but I'm not sure if this limit can be changed.

Has anybody been able to increase this limit? If yes, How?

Many thanks in advance!

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
7,408 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Ryan Hill 27,111 Reputation points Microsoft Employee
    2020-10-04T16:58:00.497+00:00

    Hi @Marcos Feliciano ,

    You can customize the PHP_INI_SYSTEM directives. In the kudu console, you can navigate to D:\home\site\wwwroot folder. Inside that, you'll see .user.ini file. Edit this file:

    upload_max_filesize = 200M  
    post_max_size = 210M  
    

    Save the file and restart your app service. You should see this change reflected on the Media Library page.

    31401-image.png

    Regards,
    Ryan

    0 comments No comments

  2. Marcos Feliciano 1 Reputation point
    2020-10-09T01:35:02.767+00:00

    Hi @Ryan Hill thanks for your answer, but the issue I'm facing is related more to increasing the size of the files I can upload to my WebApp, I've created a few other tests, but I was not able to find any doc related to increase the max file size capacity for the host itself.

    31089-image.png

    I've done many tricks on WordPress side, and I was able to see it work on WP layer, but even though I was being blocked by WebApp somehow.

    I even tried the following option under Linux hosting:

    https://azureossd.github.io/2019/01/29/azure-app-service-linux-update-php-settings/

    But now I'm using Windows due to the fact I can only have PHP 7.4, so what I'm checking if anybody has found a similar solution for Windows.

    I see from the print you provided, there is this option for "max upload file size", but do I need to install the multisite?

    On the article, I see the max file size is set to 300MB, and I'm trying to do the same, do you know how to change this setting?

    Many thanks in advance!


  3. Nicko Pekhlivanov 1 Reputation point
    2021-07-22T10:12:55.757+00:00

    It seems the problem is related to the IIS configuration.
    You may have to edit web.config, <system.webServer> section and add the following to set a 200 MB limit:

    <security>
    <requestFiltering>
    <requestLimits maxAllowedContentLength="209715200" />
    </requestFiltering>
    </security>

    The web.config file is in "wwwroot".

    0 comments No comments