# kwhat/jnativehook

Global keyboard and mouse listeners for Java.

Repository: https://github.com/kwhat/jnativehook
Canonical: https://ross.abutalabs.com/products/jnativehook
Language: Java
License: NOASSERTION
License Family: other
Topics: mouse-listeners, native-events, jnativehook, java, c, keyboard-listeners, global-hotkeys, jni, global-events
Last push: 2024-09-03T21:31:34+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 4720, "days_push": 729, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1857, forks 354 (observed 2026-08-28T04:05:45.065303+00:00)

## What it is
JNativeHook is a Java library providing global keyboard and mouse event listeners via JNI-based native system hooks. It enables applications to capture system-wide input events and post native events back to the OS, which is impossible with pure Java.

## Use cases
- implement global hotkeys in a Java application
- listen to keyboard and mouse events system-wide from Java
- build an input logger or macro recorder in Java
- capture mouse motion and wheel events outside the app window
- post synthetic native input events to the operating system

## When to choose
- you need system-wide input capture in a cross-platform Java app
- pure Java AWT/Swing listeners cannot see events outside your window
- you want a mature LGPL library with Maven Central distribution

## When to avoid
- you only need input events within your own Java window
- you need Wayland support (the library targets X11 on Linux)
- LGPL licensing is incompatible with your distribution model

## Facets
- artifact type: library
- maturity: active
- function: gui, developer-tools
- domain: desktop-applications, cross-platform
- platform: jvm, cross-platform, windows
- tags: global-hotkeys, keyboard-listeners, mouse-listeners, jni, native-hooks, input-events, automation, macos, linux

## Member repositories
- kwhat/jnativehook (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:45.065303+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:16:36.926248+00:00, confidence not recorded.
  - readme: https://github.com/kwhat/jnativehook (fetched 2026-08-28T04:05:45.065303+00:00, sha ec3d8479fb44)
- Data as of 2026-08-30T08:39:29.467469+00:00.
