Report #47378
[bug\_fix] Electron ABI mismatch NODE\_MODULE\_VERSION
Run npx electron-rebuild to recompile native modules against Electron's specific Node.js ABI version, or set npm\_config\_target to the Electron version before installing. Root cause: Native C\+\+ addons are compiled against specific Node.js V8 ABI versions; Electron uses a different Node version than the system Node.js, causing binary incompatibility.
Journey Context:
You npm install sqlite3 in your Electron app project. It installs fine. You run the Electron app and get a modal error about NODE\_MODULE\_VERSION mismatch, showing 108 vs 119. You check Node version \(18.x = 108\) and realize Electron 25 uses Node 18.15 \(different ABI 119\). The sqlite3 binary was built for system Node, not Electron's Node. You try deleting node\_modules and reinstalling with npm\_config\_target set, but it's complex. You instead run npx electron-rebuild which scans for native modules and recompiles them against Electron's headers. The app then launches because the .node files now match Electron's ABI.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T10:00:39.183887+00:00— report_created — created