Cursor Idle Fade
Fades the mouse cursor out after a period of inactivity and brings it back the instant the mouse moves
Author: Nuzza
When the mouse hasn't moved (or been clicked / scrolled) for the configured
number of seconds, the system cursors are smoothly faded out. The moment any
mouse activity happens, the cursors are restored immediately.

How it works
Windows has no "cursor opacity" setting, so the mod captures the current
system cursors, then swaps them for progressively more transparent copies
using SetSystemCursor. Mouse activity (movement, clicks and scrolling) is
detected with raw input, so nothing is polled while the cursor is visible.
While the cursor is faded, a slow watchdog (every 250 ms, or every 50 ms
while an elevated app has focus, see Limitations) also checks the mouse and
the input desktop.
On activity the original cursors are put back with SetSystemCursor (which
updates the cursor on screen immediately), followed by a reload of the saved
cursor scheme with SPI_SETCURSORS, so the scheme's own cursors are in place
again.
The mod runs in its own dedicated windhawk.exe process (a Windhawk "tool
mod").
How this differs from similar mods
-
Cursor auto-hide on idle
hides the cursor outright once the idle delay has passed and shows it again
on the first movement or click. This mod fades the cursor out gradually
instead of making it vanish abruptly:
- The fade is smooth (eased) and its length is a setting. A fade duration of
0 hides the cursor instantly, like a plain auto-hide.
- The final opacity is a setting too, so the cursor can fade to, say, 20%
and stay findable instead of disappearing completely.
If you just want the cursor gone after a delay, that mod is the simpler
choice. This one is for people who prefer a soft fade, or want the cursor
dimmed rather than hidden.
Both mods swap the same system cursors and reload the cursor scheme when
they restore, so they aren't meant to be enabled together. Pick one.
Excluded programs
Some apps, remote desktop clients such as RustDesk for example, take their
own copy of a system cursor instead of using the live one. If that copy is
made while the cursor is faded, the app keeps an invisible cursor; if it is
made while the cursor is visible, the app's cursor never fades. The mod can't
update copies other apps have made, so it doesn't fade the cursor at all
while a program from the Excluded programs setting has focus, and it brings
the cursor back as soon as such a program gets focus. rustdesk.exe is
excluded by default. If you see the same problem in another app, add its
executable name to the list.
The program is identified by the process that owns the focused window.
Windows Store (UWP) apps are hosted by ApplicationFrameHost.exe, so they
can't be excluded by their own name, and excluding ApplicationFrameHost.exe
would exclude all of them.
Limitations
- Only the standard system cursors are faded (arrow, I-beam, hand, resize,
cross, help, etc.). Apps that draw their own cursor (some games, some
browsers/design tools) are not affected.
- The animated busy/working cursors are left alone on purpose.
- Monochrome cursors can't be made partially transparent. With the default
Windows cursor scheme this includes the text (I-beam) and precision
(crosshair) cursors. They stay unchanged until the fade passes 50% and then
disappear; if Final opacity is 50 or more, they stay visible.
- The faded copies are single-size bitmaps. With mixed-DPI monitors or a
larger pointer size, the cursor may change size while it fades and snap
back when restored.
- Restoring reloads your saved cursor scheme, so cursors changed temporarily
by another tool via
SetSystemCursor revert to the saved scheme.
- Windows doesn't deliver raw mouse input to a normal (non-elevated) process
while an app running as administrator has focus (Task Manager, for
example). In that case the mod falls back to checking the cursor position
and mouse buttons (about 5 times a second): the cursor still reappears
when you move or click, but scrolling alone isn't noticed. The mod notices
which app has focus and switches back to raw input by itself.
- If the cursor is faded while a secure screen (UAC prompt, lock screen)
takes the input, it is restored automatically.
Recovery
If the mod's process crashes while the cursor is faded, it tries to restore
the cursors before it exits. If the process is killed instead, the mod
restores the cursors the next time it starts. You can also re-apply your cursor scheme
in Settings > Bluetooth & devices > Mouse > Additional mouse settings >
Pointers.