Answers.Body: <p>My guess is that your php <code>upload_max_filesize</code> is set to 16M, you'll need to adjust that.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-07-26T21:15:42.723Z
Answers.LastActivityDate: 2018-07-26T21:15:42.723Z
Answers.UserDisplayName: Brett Moore
Answers.Body: <p>Since Craft 2.1 there is a setting <code>maxUploadFileSize</code> in <code>craft/config/general.php</code>. You should change this setting as well. Default value is 16777216 (16MB).</p>
  
  <p><a href="https://docs.craftcms.com/v2/config-settings.html#maxuploadfilesize" rel="nofollow noreferrer">https://docs.craftcms.com/v2/config-settings.html#maxuploadfilesize</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-05-31T21:23:15.247Z
Answers.LastActivityDate: 2019-05-31T21:23:15.247Z
Answers.UserDisplayName: Dusan
Body: <p>I'm adjusting the maxUploadFileSize in Craft, to 50MB.<br>
  In following the post below, I made several adjustments to both: php.ini and craft/config/general.php.
  <a href="https://stackoverflow.com/questions/3263480/upload-max-size-in-php">https://stackoverflow.com/questions/3263480/upload-max-size-in-php</a></p>
  
  <p>First, I adjusted settings in php.ini:</p>
  
  <pre><code>upload_max_filesize 
  post_max_size
  </code></pre>
  
  <p>In general.php (craft/config), the following was already set:</p>
  
  <pre><code>  define('URI_SCHEME',  ( isset($_SERVER['HTTPS'] ) ) ? "https://" : "http://" );
    define('SITE_URL',    URI_SCHEME . $_SERVER['SERVER_NAME'] . '/');
    define('BASEPATH',       realpath(CRAFT_BASE_PATH . '/../') . '/');
  
   return array(
  
    '*' =&gt; array(
          'environmentVariables' =&gt; array(
          'omitScriptNameInUrls' =&gt; true,
          'siteUrl'  =&gt; SITE_URL,
          'basePath' =&gt; BASEPATH,
          'maxUploadFileSize' =&gt; 62914560,
          ),
    ),
    'dev' =&gt; array(
      'devMode' =&gt; true,
    )
  
  
   );
  </code></pre>
  
  <p>I know that that is around 62MB, but I keep receiving an error message saying that there is a 16MB limit on files.  All other files great than 2MB and less than 16MB now are upload-able.<br>
  Can anyone make a suggestion as to why the standard CraftCMS default of 16MB is now in place?</p>
  
  <p>Thanks for any leads</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-25T21:23:33.220Z
Comments.Text: Basic question, but worth a double check. Is your `maxUploadFileSize` setting being applied to your current environment?
Comments.UserDisplayName: Simon Kuran
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-25T22:17:28.653Z
Comments.Text: Go into the Utilities section in the Control Panel, click on PHP info and do a Cmd/Ctrl+F for `upload_max_filesize`. Does it say `50M`?
Comments.UserDisplayName: Mats Mikkel Rummelhoff
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-25T22:26:33.103Z
Comments.Text: Also, what web server is this? For Nginx, for example, you'll want to do `client_max_body_size 0;` to set it to "no limit" https://github.com/nystudio107/nginx-craft/blob/master/sites-available/somedomain.com.conf
Comments.UserDisplayName: andrew.welch
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-26T20:05:59.040Z
Comments.Text: Thanks - this is IIS - Windows Server.
  Regarding applying maxUploadFileSize to my current environment, is there a command which will reveal which settings are being applied from which (if there are multiple) general.php file?
Comments.UserDisplayName: buck1112
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-26T21:58:04.560Z
Comments.Text: Is this Craft 2 or Craft 3?
Comments.UserDisplayName: Brad Bell
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-07-27T16:16:17.040Z
Comments.Text: This is Craft 2
Comments.UserDisplayName: buck1112
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-08-28T05:14:25.630Z
Comments.Text: IIS has a maxAllowedContentLength setting you can adjust in web.config that you might be running into.
Comments.UserDisplayName: Brad Bell
Tags: <upload><limit>
Title: Adjusting Max File Size - Stuck at 16M After Adjusting general.php
ThreadText: # Adjusting Max File Size - Stuck at 16M After Adjusting general.php
  
  (Asked by: username_0 on 2018-07-25)
  
  I'm adjusting the maxUploadFileSize in Craft, to 50MB.  
  In following the post below, I made several adjustments to both: php.ini and craft/config/general.php.
  <https://stackoverflow.com/questions/3263480/upload-max-size-in-php>
  
  First, I adjusted settings in php.ini:
  
  ```
  upload_max_filesize 
  post_max_size
  
  ```
  
  In general.php (craft/config), the following was already set:
  
  ```
    define('URI_SCHEME',  ( isset($_SERVER['HTTPS'] ) ) ? "https://" : "http://" );
    define('SITE_URL',    URI_SCHEME . $_SERVER['SERVER_NAME'] . '/');
    define('BASEPATH',       realpath(CRAFT_BASE_PATH . '/../') . '/');
  
   return array(
  
    '*' => array(
          'environmentVariables' => array(
          'omitScriptNameInUrls' => true,
          'siteUrl'  => SITE_URL,
          'basePath' => BASEPATH,
          'maxUploadFileSize' => 62914560,
          ),
    ),
    'dev' => array(
      'devMode' => true,
    )
  
   );
  
  ```
  
  I know that that is around 62MB, but I keep receiving an error message saying that there is a 16MB limit on files. All other files great than 2MB and less than 16MB now are upload-able.  
  Can anyone make a suggestion as to why the standard CraftCMS default of 16MB is now in place?
  
  Thanks for any leads
  
  **Tags:** upload, limit
  
  > **Comments:**
  > **username_1**: Basic question, but worth a double check. Is your `maxUploadFileSize` setting being applied to your current environment?  
  > **username_2**: Go into the Utilities section in the Control Panel, click on PHP info and do a Cmd/Ctrl+F for `upload_max_filesize`. Does it say `50M`?  
  > **username_3**: Also, what web server is this? For Nginx, for example, you'll want to do `client_max_body_size 0;` to set it to "no limit" https://github.com/nystudio107/nginx-craft/blob/master/sites-available/somedomain.com.conf  
  > **username_0**: Thanks - this is IIS - Windows Server. Regarding applying maxUploadFileSize to my current environment, is there a command which will reveal which settings are being applied from which (if there are multiple) general.php file?  
  > **username_4**: Is this Craft 2 or Craft 3?  
  > **username_0**: This is Craft 2  
  > **username_4**: IIS has a maxAllowedContentLength setting you can adjust in web.config that you might be running into.  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_5 on 2018-07-26. Score: 1
  
  My guess is that your php `upload_max_filesize` is set to 16M, you'll need to adjust that.
  
  
  ---
  
  ### Answer by username_6 on 2019-05-31. Score: 1
  
  Since Craft 2.1 there is a setting `maxUploadFileSize` in `craft/config/general.php`. You should change this setting as well. Default value is 16777216 (16MB).
  
  <https://docs.craftcms.com/v2/config-settings.html#maxuploadfilesize>
  
  
  ---
  
  