26

My website contains a form that allows users to upload and attach scanned documents (.jpg, .pdf, ...) to their order.

The documents are pretty small in file size (~ 200 KB up to ~ 10 MB, depending on the user).

I've configured my webserver to accept files up to 128 MB. Should I show this file size limit to my users regardless?

  • 34
    YES. If you do not, people are going to have to guess what file size is permitted and what isn't. Also, what happens if you choose to reduce or increase the file size? Things will get even worse. – Majo0od Apr 7 '17 at 15:10
  • 2
    You really think a 10 MB PDF file is "small"? I've got 200+ page books with images, diagrams, and equations that aren't much bigger than that. But yes, show the max allowable size, and prominently. – jamesqf Apr 7 '17 at 23:23
  • 5
    @jamesqf I bet your PDF contains text. Scanned PDFs contain images. – chrylis Apr 8 '17 at 18:35
  • 3
    If documents are typically 200KB – 10MB, why accept files as large as 128MB? Will this not lead to other avoidable problems? – cloudworks Apr 9 '17 at 4:57
  • 2
    @jamesqf Happy to check it out, but I'm willing to bet the primary contents are text while pictures are a combination of vector and raster images. In a scanned PDF, it's 100% raster images. – chrylis Apr 10 '17 at 2:02
54

Echoing the others, yes, don't make your users guess.

Not showing them what they're allowed to do with their form is akin to, for example, providing a single text field input with the label Contact: and only after they have entered their email address alerting them that the input is invalid because you expected their postal code.

Additionally, check the file size in the browser before you let them submit the form. You don't want them uploading a 1 GB file only to have the server discard it after the POST is complete, possibly hours later. This may explain partly why you have abandonment after the error.

  • 2
    Isn't it not to make the users guess, rather than “think”? (Yes, I know you are quoting an aphorism.) – can-ned_food Apr 7 '17 at 18:06
  • @can-ned_food D'oh! I had originally used that, actually, and refactored it when I moved the link. I'll update it ;) – msanford Apr 7 '17 at 18:11
  • 13
    I totally agree, but I can't help thinking that, on the other hand, if typical document sizes are 200 KB - 10 MB, a limit of 128 MB is almost essentially equivalent to "unlimited". Also, I'd be really curious to test if displaying "128 MB" vs nothing at all counter-intuitively increased the average size of the files users uploaded. Would be an interesting long term test, perhaps A/B style... – Jason C Apr 7 '17 at 22:03
  • 10
    1. Detect whether File API is available 2. Hide the filesize note if 1 is true (minimalism!!) 3. 'onchange' check file.size 4. Throw a fit if it's too big. Everyone's happy. – transistor09 Apr 8 '17 at 17:28
  • @JasonC In that case (and only in that case) I think you can un-show the maximum size and perform an in-browser test, just in case. – yo' Apr 9 '17 at 16:37
28

No, not at first. Most of your users are going to upload files smaller than 128M anyway and won't care about the limit. Don't show useless information to them. Don't make them think. I am sure your UI will benefit from having more free space.

However, do check the file size and inform the users of the limit when they try to upload a file that is too large: your error message should not be "Error: file too large", but "Error: this file is too large (140MB). The maximum size allowed is 128 MB".

Having your users figure out exactly by how much they have to make their file smaller by trial and error is a great way to drive them into a murderous rampage.

  • 4
    Be careful about rounding if you display both sizes. Showing the same value for both (in the case where the file 128MB+1byte) would be confusing. – CodesInChaos Apr 8 '17 at 19:33
  • 2
    Where the hard limit is this far above the "typical" maximum file, I think not showing a maximum (but checking before uploading) is better. However, as an other answer questions, 128MB for the hard-limit may be too large. Also, consider a warning for files more than, say, 10-20MB (e.g. to allow a mobile user to delay the upload until they're on WiFi). – TripeHound Apr 10 '17 at 8:23
  • 1
    -1 - This hit me not so long ago - I filled a long form only to get notified at the end that the file I wanted to get processed is too large. It was really bad experience and downgrading quality of images in PDF that wasn't even generated by me wasn't an option. Someone I won't name did what you advise and wasted a significant portion of my time. – Mołot Apr 10 '17 at 13:08
8

I don't think you should show or accept 128 MB files via an upload form unless you're pretty sure your user have good speed. Even on 10mbps, 128mb file is 2 minutes of upload: it's a rather long process that can be easily broken.

That said, I would limit and show something like 10 MB or even smaller. Good idea is to specify accepted file formats in the form and add some kind of progress indicator as a feedback.

  • 2
    I noticed that a large percentage of users leave the page, as soon as an error occurs (even with descriptive, translated messages). This is the reason I set the limit that high - I don't think that anyone will ever run into it. Do you still think that I should lower the limit? – Physikbuddha Apr 7 '17 at 15:28
  • 1
    @Physikbuddha what kind of errors do you mean? – Runnick Apr 7 '17 at 16:15
  • Invalid values in some of the text fields. In example there is a date field users can fill out with the help of a jQuery calendar. There is also a hint showing the required date format. However, some users enter invalid values like 082016. Or users choose an invalid combination of products to order. Uploading an image too large for the webserver to handle would cause another error message to appear, that's what I'm trying to avoid. – Physikbuddha Apr 7 '17 at 17:03
  • 1
    @Physikbuddha this is why you should do client-side validation first and disable submission until the fields are filled out correctly (ideally with an informative message near the disabled submit button advising the user what needs to be corrected). For optional fields (such as a date), simply test whether the field is valid or empty, before permitting submission of the form. – Doktor J Apr 7 '17 at 20:11
  • 1
    Other than that, I agree that displaying a smaller size -- though maybe something closer to 20MB-25MB, to ensure there's enough "headroom" so a user doesn't say "oh darn, I have an 11MB file, guess I can't upload it :("; no one will be disappointed that an oversized file uploaded successfully, but if the upload fails for some other reason (connection reset, etc) and their file was below the stated size you can almost guarantee they'll be unhappy. – Doktor J Apr 7 '17 at 20:13
0

I think it is always important to present users with useful information that will make the process more seamless. So, I think it would be a good idea to show the maximum file size. Perhaps also display it in a more "friendly" notation, such as GB. Most users probably won't understand the MB. Try to display the value in different formats.

  • 12
    I don't think that users will have problems recognizing MB- it's probably the most-used file size notation (mostly because formatted documents are too large for KB to be useful and too small for GB to be useful, and OS's won't present in GB until you get up to ~75% of one). 128 MB is more useful and readable to most people than 0.12 GB. – Delioth Apr 7 '17 at 19:06
  • 4
    "Most users probably won't understand the MB." Uh, what? – Jason C Apr 7 '17 at 21:59
0

Yes of course, You will never know what users are thinking.

And if the upload fails, they will start contacting you for support.

So give it to them at the start and stay on the safe side.

0

If the file limit exceeds the average file size uploaded by users by a large threshold (as in your exapmle), displaying the limit would only add clutter. However, you should check the file size on the client, as soon as the user selects it, to avoid a potentially long-running upload that only results in an error message.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.