Image size is larger locally than it is on server

answered
#1

Hi all,

My image size is 741KB on my computer and Github, but when I load the website which is hosted on Netlify, image size is 2,194KB. I downloaded the big file and see all width, height, resolutions and bit depth are the same.
I am using Gatsby + NetlifyCMS
For example:
On https://gatsby-netlify-cms.netlify.com/ file home-jumbotron.jpg is 437KB
But on github https://github.com/netlify-templates/gatsby-starter-netlify-cms/blob/master/static/img/home-jumbotron.jpg file size is 138KB

#2

Hi @qnguyen ,

That’s a great question. I checked the repo and I see that you’re using https://www.gatsbyjs.org/packages/gatsby-remark-images/ . If you just deploy a static file we don’t change it. The plugin there is transforming and generating images for you.

#3

Hi,

Wondering are there any ways to update files in public folder after deploying? I want to update those big images.

#5

Deploys are immutable. But if you update the files in your repo or change your build process then assuming the repo is linked to a netlify site, we will rebuild and your new deploy will be published to your production URL.