---
type: Article
title: 11ty upgrading node in netlify
description: Simon Cox fixes a failed 11ty build on Netlify by identifying a mismatch in Node versions, updating config settings and documenting the troubleshooting process.
resource: https://www.simoncox.com/short-articles/2024-10-15-11ty-upgrading-node-in-netlify/
tags: [Shorticles, Eleventy]
timestamp: 2024-10-15
---


I upgraded the image plugin for 11ty on a small site which had an unintended chain of issues! 

I noticed that the Source control had node elements in it,  even though I have node_modules in my gitignore file. After some investigation and testing I realised that I must have deployed the site before adding the gitignore. Really should not have node_modules deployed to the repository even though it is private.

To remove the node_modules from the repository I moved the folder up a level and committed and synced the files. That removed the node_modules from the repository. I then moved the node_modules folder back into the local site and ran a build - all was ok.

I checked Netlify and the build had failed. 

It turned out (i.e. head scratching and testing for a while) is wasn't my local Node but the Node version on Netlify that needed upgrading - of course it was. 

With the node_modules in the build, Netlify had used the node_modules I had provided to create the build - which is a great feature but not what was needed. As soon as I had removed them Netlify used the default node_modules which failed to build because apparently node needed upgrading. 

On the Netlify Site Configuration > Build & Deploy > Dependency management (scroll down) to find and configure the Netlify version of Node - it was 15 and I apparently needed 18, so set to 20. Bingo - built and deployed magnificently!

I hope this note helps someone but it is really for me the next time I get this issue on another site and don't realise I fixed it before. 


[Read full article](https://www.simoncox.com/short-articles/2024-10-15-11ty-upgrading-node-in-netlify/)
