Exit code 130 means your process received SIGINT, usually from pressing Ctrl+C. This is expected behavior when stopping a dev server. If you didn't press Ctrl+C, check for runaway processes or signal handling issues.
Exit code 130 (128 + 2) indicates the process received SIGINT—the interrupt signal sent when you press Ctrl+C. In most cases, this is completely expected behavior. When you press Ctrl+C to stop a development server (`npm start`, `npm run dev`), the process receives SIGINT and terminates with exit code 130. npm then reports this as ELIFECYCLE because any non-zero exit triggers that message. This is not really an error—it's the correct behavior for an interrupted process. However, if you didn't press Ctrl+C and see this error, something else is sending SIGINT to your process.
If you pressed Ctrl+C, exit code 130 is correct:
^C <-- You pressed Ctrl+C
npm ERR! code ELIFECYCLE
npm ERR! errno 130This is expected. The process stopped exactly as you requested. npm just reports all non-zero exits as errors.
For development servers, you can safely ignore this message. The server stopped, which is what you wanted.
If it bothers you, you can suppress the error output:
npm start 2>/dev/null || trueTo exit cleanly with code 0 instead of 130:
process.on('SIGINT', () => {
console.log('\nGracefully shutting down...');
// Cleanup code here
process.exit(0);
});This prevents the non-zero exit code.
Puppeteer can intercept SIGINT. Disable it:
const browser = await puppeteer.launch({
handleSIGINT: false
});This prevents Puppeteer from calling process.exit() when you press Ctrl+C.
If CI fails on exit 130 when it shouldn't:
GitHub Actions:
- run: npm start &
- run: sleep 10
- run: kill -2 $! # This will exit 130, which is fine
continue-on-error: trueOr check the exit code explicitly in scripts.
nodemon v1.18.1+ explicitly exits with 130 on SIGINT. If this causes issues:
npm install [email protected] --save-devNote: This is an older version and may have other issues with newer Node.js versions.
Exit 130 vs other signal exits:
- 130 (SIGINT): User interrupt (Ctrl+C)
- 137 (SIGKILL): Forced kill, no cleanup possible
- 143 (SIGTERM): Graceful termination request
On Windows, Ctrl+C may report exit code 2 instead of 130 in native CMD/PowerShell, but WSL and Git Bash will show 130.
If you're seeing exit 130 without pressing Ctrl+C, check:
1. Other terminal tabs/windows that might be sending signals
2. Scripts that use kill commands
3. Process managers that restart processes
4. IDE terminal integrations that might send signals
For production, exit 130 should never occur because you shouldn't be running npm start directly in production—use a process manager or run node directly.
npm error code ENOENT npm error syscall spawn git npm error path git npm error errno -4058 npm error enoent An unknown git error occurred
How to fix "spawn git ENOENT" in npm
npm error code E401 npm error Incorrect or missing password.
How to fix 'E401 Unable to authenticate' errors with npm private registries
npm notice access token expired or revoked. Please try logging in again.
Token has expired - npm authentication failure
npm ERR! code EAI_AGAIN
How to fix "EAI_AGAIN" in npm
npm error code E403 npm error 403 Forbidden - PUT https://registry.npmjs.org/<package>
How to fix 'E403 Forbidden' error in npm