Out of memory crash on Windows 10 PC

As I said, it isn't running out of memory per-se, it is running out of heap. This means that memory is being allocated/used faster than it can be cleared. There are plenty of generic guides out there that give ideas about how to reduce the issue - of course, these don't always directly help with Node-RED which is hiding the complexities of Node.js from you.

But as I also said, in Node-RED, the starting place is to look at what contrib nodes you are using. Firstly make sure that they are current. 2nd would be to check here and on GitHub for issues with the nodes you are using. 3rd would be to see if there are alternative nodes.

It is possible to run node-red in a debug environment which would potentially let you get into the weeds with what is using up memory. However, this is a really complex task and requires a fair bit of knowledge to set up as well as to make sense of.


I looked again at your other issue about manual start. You've mixed up the order of the parameters:

node C:\Users\tbg\AppData\Roaming\npm\node_modules\node-red\red.js --max-old-space-size=81928 red.js

That should work and will use the default ~/.node-red folder for userDir. This will likely delay the problem but at the cost of longer pauses in your flows when GC does actually kick in.

Actually it is very easy. You have enough memory not to worry about its overheads.

https://www.google.com/search?q=running+node+red+under+pm2