pyHook is a python wrapper for global input hooks in Windows. Specifically it wraps the Windows SetWindowsHookEx API function using low-level keyboard (WH_KEYBOARD_LL) and mouse (WH_MOUSE_LL) hooks.
The pyHook package provides callbacks for global mouse and keyboard events in Windows. Python applications register can event handlers for user input events such as left mouse down, left mouse up, key down, etc. and set the keyboard and/or mouse hook. The underlying C library reports information like the time of the event, the name of the window in which the event occurred, the value of the event, any keyboard modifiers, etc. Events can be logged and/or filtered.
This project provides compiled releases of the pyHook library in the file releases section of the project site. It is advised that you use the latest release. If you choose to use the precompiled installer, all you have to do is double-click the installer and follow the install wizard.
The project also makes source code releases, also posted in the file releases section. You can if you wish get the source zip, and compile the code yourself, using these instructions. This will produce a binary installer for you, just like the ones released by the project.
You can also pull the latest code from git, if you are feeling adventurous.
pyHook is licensed under the MIT Licence.
The original author of this library is Peter Parente (though he no longer maintains this project.)
If you need help, please post on the help forum of the project site.