Why is the cache so big?

Every time our site builds, it says Starting to download cache of 2.4GB

I don’t understand why the cache is so big. It doesn’t need to be, for sure, and extracting it eats away precious build minutes. If it’s caching the node_modules directory, that’s fine, but that one’s only supposed to be around 400MB, so then there must be another 2GB of junk.

Also, slightly related, how can I clear this cache, and how can I see what’s in it?

Our site name is mijn-enexis.netlify.app

Hello @enexify :wave:

Welcome to Netlify Community, and thank you for sharing this question!

I took a look at your most recent build log with one of our Support Engineers. It looks like Netlify is taking 13 seconds to download your build cache, and your total build time is taking 3m36s. Are you concerned that you were being billed for a longer amount of time?

As for inspecting the cache, we do not currently have a utility for you to be able to do that. You can see the directories we cache in our docs. Here is a specific resource about managing build dependencies. Additionally, I would encourage you to file an issue on the build-image repo if there is a cache inspection feature that you would like to see!

Lastly, it is possible to clear your cache for the next deploy using the “clear cache and deploy site” button. There are some helpful tips outlined in our troubleshooting doc. One thing to note is that if you clear your cache, we’ll have to pull the dependencies listed in your package.json file again and it will likely take longer than 13s to do that.