# How to update function modules?

**URL:** <https://discourse.nodered.org/t/how-to-update-function-modules/101850>\
**Category:** General\
**Created:** [2 October 2026 21:42 UTC](https://discourse.nodered.org/t/how-to-update-function-modules/101850 "2026-10-02T21:42:31Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![AndreKR](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/andrekr/32/81657_2.png) [@AndreKR](https://discourse.nodered.org/u/AndreKR)\
**Post date:** [2 October 2026 21:42 UTC](https://discourse.nodered.org/t/how-to-update-function-modules/101850/1 "2026-10-02T21:42:31Z")

</div>

A Function node is currently using an old version of a package I added under "Setup". How do I get it to update?

I tried:

- Deleting the module from the Setup tab an re-adding it.
- Deleting the module from the `node_modules` directory in the project directory.
- Deleting `package-lock.json` from the project directory.
- Deleting `.package-lock.json` from the `node_modules` directory

Now it's gone - I deleted it - but Node-RED won't install the latest version.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [3 October 2026 07:09 UTC](https://discourse.nodered.org/t/how-to-update-function-modules/101850/2 "2026-10-03T07:09:26Z")

</div>

It is very rarely a good idea to mess with npm's files. I would have expected the package to appear in Manage Palette and allow you to update it there.

To recover the situation go into your .node-red folder (assuming it is a conventional install) and run  
`npm remove the_package`  
`npm install the_package`  
If there are any errors there then come back here. Otherwise restart node-red and it should be ok.
