WIN
npm
3 log locations · Windows, macOS, Linux
- Old npm versions also dropped npm-debug.log in the current directory when an install script crashed.
Where npm keeps its logs
npm logs to %LocalAppData%\npm-cache\_logs\ on Windows.
npm logs to ~/.npm/_logs/ on macOS.
npm logs to ~/.npm/_logs/ on Linux.
Paths are printed exactly as npm writes them. Environment variables like %LOCALAPPDATA% and $XDG_STATE_HOME are never expanded, so a path can be pasted straight into a shell. Where a path differs between installer types or shipping flavours, each one is racked as its own card below - why that happens.
MAC
LNX