Skip to content

Instantly share code, notes, and snippets.

@anshumanb
Created July 20, 2021 05:54
Show Gist options
  • Save anshumanb/19b2ae62f8fbad8138efb571bbe163b1 to your computer and use it in GitHub Desktop.
Save anshumanb/19b2ae62f8fbad8138efb571bbe163b1 to your computer and use it in GitHub Desktop.
Set up focus follows mouse on Windows 10
  1. Navigate to Control Panel > Ease of Access > Ease of Access Center > Make the mouse easier to use
  2. Check "Activate a window by hovering over it with the mouse" and hit OK
  3. In the registry editor, navigate to Computer\HKEY_CURRENT_USER\Control Panel\Desktop
  4. Update ActiveWndTrkTimeout to 300
  5. Update UserPreferencesMask by subtracting 40 bits from the first hex value e.g. DF -> 9F
  6. Log out and log back in

Source: https://winaero.com/enable-xmouse-window-tracking-windows-10/

@abstractionmage
Copy link

abstractionmage commented Jul 27, 2025

Step 1 and 2 seem to be enough to enable focus follows mouse. Everything else is just to make windows focused this way not be automatically brought to the front. Would you mind adding this as context to your guide @anshumanb?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment