Skip to content

Is it safe to delete node-gyp headers cache?

Node.js header files node-gyp downloads to build packages that include native code.

Safe

Its owner recreates it by itself when it needs it, and nothing you made is lost.

~/Library/Caches/node-gyp

What it is

Some npm packages include native code that's compiled when they're installed. node-gyp, the build tool used for them, downloads the development files for each Node.js version it builds for and keeps them here, one folder per version. Folders for versions you no longer use stay until they're removed.

If it's removed

The next time a package with native code is built, node-gyp downloads the files for that Node.js version again.

How it's removed

Moved to the Trash, where you can restore it.

PRO

The free analyzer finds it and explains it. Removing it is Pro, after a review sheet that lists every move and command. It starts checked in the Cleanup checklist, except inside Documents or Desktop.

Sources

Last checked on 26 Sep 2026. Every entry is written and checked by hand; the app and the command-line tool use the same words.