---
title: "Setting max file upload size in Drupal"
description: "When working with images, you may want to restrict them in ways that will help keep your site optimized. While you may limit them in physical size, you may also want to restrict them as far as..."
url: https://www.inmotionhosting.com/support/edu/drupal/drupal-set-max-upload-size/
date: 2013-11-27
modified: 2023-10-13
author: "Scott Mitchell"
categories: ["Drupal"]
type: post
lang: en
---

# Setting max file upload size in Drupal

When working with images, you may want to restrict them in ways that will help keep your site optimized. While you may [limit them in physical size](/support/edu/drupal/set-max-min-size/), you may also want to restrict them as far as maximum file size. This will force the node creators to optimize images if they exceed the limit even if they fit within any size restrictions you may have set.

Ignite your online presence with cutting-edge [Drupal Website Hosting](https://www.inmotionhosting.com/drupal-hosting). Elevate speed, security, and reliability for a seamless website experience.

## How to set maximum file upload size in Drupal

1. [Log into your Drupal admin interface](/support/edu/drupal/how-to-log-into-the-drupal-admin-dashboard/).
2. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-menu.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-menu.png) Using the top menu bar, **Menu** Tab.
3. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-structure.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-structure.png) Now a second menu bar will appear. Click on the **Structure** tab to continue.
4. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-content-type.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8__common-images_select-content-type.png) From here, click on the **Content Types** option from the *Structure* page.
5. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-size-settings_1-select-manage-fields.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-size-settings_1-select-manage-fields.png) Now that you are on the *Content Types* page, find the content type you want to set the image settings for. In our example, we will work with the *Article* type. Look tot he dropdown on the right side of the *Article* row and Click on **Manage Fields**.
6. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-size-settings_2-select-edit.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-size-settings_2-select-edit.png) You are now taken to the *Manage Fields* page. From here you see a list of the current fields for *Article* content types. Click on the **Edit** option from the dropdown to the right side of the *Image* field row.
7. [![](https://www.inmotionhosting.com/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-max-upload-filesize_4-set-max-filesize.png)](/support/wp-content/uploads/2013/11/edu_Drupal-8_108_set-max-upload-filesize_4-set-max-filesize.png) The *Image Settings* page appears, where you will need to find the **Maximum Upload Size** field. Here you can enter the maximum size you want any uploaded files to be. You may set the size by kb, or MB. For our example, we are setting them at 2MB. **Note: **The maximum size entered here must first pass the settings in your php.ini file. This size setting is noted under the field itself. If you set a size here that is larger than the php.ini file setting, the file will be restricted by the php.ini setting. You may need to [change your **upload_max_filesize** setting in your php.ini](/support/website/update-local-php-settings/) as well.
8. Once you have entered your size restrictions for either one or both fields, click on the **Save Settings** button. Your new filesize settings will now be active.
