Skip to content
Node.js global keyboard and mouse listener.
C M4 JavaScript C++ Roff CMake Other
Branch: master
Clone or download
Latest commit eefab9c Aug 1, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github add github templates for issues and PRs Mar 19, 2018
docs fix: update repo name Aug 1, 2019
libuiohook Make POSIX-test-compatible Nov 1, 2018
src Added alt, ctrl and meta May 10, 2018
test/specs Add the ability to track rawcodes and keycodes Nov 7, 2018
.gitignore Added full documentation May 8, 2018
.npmignore + Fix cross compilation for linux x64 Feb 15, 2018
.travis.yml change 32b arch name in travis build Nov 1, 2018 chore: bump version Aug 1, 2019
CMakeLists.txt feat: add electron 4+ win support Mar 28, 2019
LICENSE Initial commit Dec 10, 2016 chore: drop electron < 4 support. add electron 6 support. Jul 31, 2019
_config.yml Set theme jekyll-theme-midnight May 10, 2018
appveyor.yml Try switching to VS2017 Mar 8, 2019
build.js use arg 'arch' for cmakejs May 27, 2019 feat: drop segfault-handler dependency Dec 17, 2018
index.d.ts Add the ability to track rawcodes and keycodes Nov 7, 2018
index.js Fix NPE when trying to call releaseCallback Dec 28, 2018
install.js fix: update repo name Aug 1, 2019
package-lock.json Add commandline options to build.js Apr 8, 2019
package.json chore: bump version Aug 1, 2019


Build status Build Status Gitter chat NPM version


Node.js global native keyboard and mouse listener.

This module can handle keyboard and mouse events via native hooks inside and outside your JavaScript/TypeScript application.

Found a bug? Have an idea? Feel free to post an issue or submit a PR.

Check out the documentation.

Platform support

  • Versions >= 0.6.0 support only officially supported platforms versions.
  • Versions 0.5.X are the last to support Electron < 4.0.0
  • Versions 0.4.X are the last to support for Node < 8.0 and Electron < 2.0.0


iohook provides prebuilt version for a bunch of OSes and platforms.

npm install iohook --save # or yarn add iohook


Q. Does this module require Java ?

A. No, this module doesn't require Java (like jnativehook) or any other runtimes.

Q. Is iohook compatible with Node/Electron version X.Y.Z ?

A. We try to match the currently supported version of both Node and Electron.


Are you using iohook in your project ? Please tell us in a PR so we an add it to the list !


Thanks to kwhat for the libuiohook project and ayoubserti for the first iohook prototype.

  • vespakoen (prebuild system implementation)
  • matthewshirley (Windows prebuild fix)
  • djiit (project & community help)
  • ezain (add feature enable/disable mouse click propagation)
  • anoadragon453 (electron 4+ support)
  • All the other contributors. Feel free to extend this list !
You can’t perform that action at this time.