I am building a social media app for gardeners. One of the things they can do is upload images of their gardens. I am storing everything in Amazon aws s3.

I don't want the user to be able to upload large image files because if those images are then displayed on a webpage they may cause that webpage to load slow.

Most images will be displayed in an image carousel that contains a row of image thumbnails, an image preview section, and when you press on the image preview an enlarged image will be shown.

So if a webpage can contain multiple images what filesize limit would be recommended?

  • 1
    If you allow other people to view the originally uploaded image, make sure to at least sanitize its metadata first. Images can contain a lot of extra data that you don't necessarily want other people seeing, like the GPS coordinates of where the image was taken.
    – Yay295
    Aug 2, 2020 at 7:12
  • 1
    I was aware of this @Yay925, its called exif data. But thanks for the heads up
    – Maurice
    Aug 2, 2020 at 10:05

1 Answer 1


I would create a sized-down version of each image that you use for the thumbnails. That way, nobody will use a large amount of bandwidth until they explicitly click on an image to enlarge it.

As for the full-size images, it all depends on how much you value high-res images versus performance. On the low end, consider a 1MB limit each. On the high end, maybe 3-5 MB at the most.

  • 2
    You don't even have to show the original image when it's enlarged. There could be a download button to get the original image, but all copies actually displayed on the site could be shrunk.
    – Yay295
    Aug 2, 2020 at 7:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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