Image clarity decline on upload

Hi Team,

I’m working on an Umbraco 13.5 website and have noticed a decline in image clarity when uploading images to the Media section.

What surprised me is that after sharing the media link with my team, some members received a compressed version of the image, while others saw the original high-quality image.

Has anyone encountered this behavior before? Any idea what might be causing it?

Any help is appreciated.
Thanks!

Someone correct me if I’m wrong, but I think Umbraco does two things:

  • Upload the media (in this case an image) as-is. I don’t think by default that there is any image manipulation during upload.
  • Not sure if it’s still the case, but Umbraco would generate a lower quality image for displaying in the backoffice.

So if you have the link to the media item directly (like https://website.com/media/abcde/image.jpg) you should get the original, unaltered version. However, if you apply some transformations using querystrings ImageSharp will generate a different image and perform stuffs on the image.

If everyone has the same link, linking directly to the image file, everybody should get the original image. If they link to the ‘thumbnail’ version, the quality is less and if you use querystring parameters and let ImageSharp do it’s thing, you might get different results.

2 Likes

Umbraco doesn’t create its own thumbnail versions anymore.

There are a few different things that could be going on here, @arun-vr-official are you able to share example URLs or the images themselves?

2 Likes

Thanks @LuukPeters @JasonElkin for your attention

I really appreciate you both taking the time to look into this—thank you for your help and for being willing to assist!

I managed to figure it out. The issue was related to response caching, and excluding the /media path resolved it:

app.UseWhen(
    context => !context.Request.Path.StartsWithSegments("/media"), 
    app => app.UseResponseCaching()
);

Without excluding /media, all images were being compressed to a fixed width of 500px, causing a loss of clarit

Thanks again for your help and for fostering such a great community! :blush:

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.