npm install --ignore-scripts package

Category: Node.js & npm/yarn

npm install --ignore-scripts package

Install a package without running its postinstall scripts — useful for security

Prevents npm from running the package's install scripts (postinstall, preinstall). Reduces supply-chain attack risk from malicious packages running arbitrary code on install.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.