I'm looking for a program that I can use to control the mouse from the keyboard. I think a video can explain it much better than I could, so please check out Mouser from lifehacker.com:


Unfortunately, it's only for Windows, but something like this would be the perfect solution. I found a lot of help on mapping keys to programs, but nothing about mapping keys to mouse control.

7 Answers 7


If you look at that HackaDay article, it says he created Mouser.exe after viewing a presentation from a guy at Google. Google's known for its use of linux, right? One of the links from your HackaDay article took me here: http://www.semicomplete.com/projects/keynav/ And here is a demo of keynav in action

Just tested on Ubuntu 10.10 and it works fine. I had to install libxdo-dev before it would build (make), but then it ran fine. Note there's no 'make install' target, so just copy the keynav binary it builds to someplace in your path (~/bin, /opt/bin, etc).

Doesn't work awesome with dual monitors.Edit: NM. Split at least once, than use Shift+[hjkl] to move the divider around. That can jump you to the other screen.

  • keynav is great, I've been using it for years. I'd also like to point out warpd, which has a few more features. It's currently only packaged for Arch, though, which is why I'm posting this as a comment instead of an answer. Sep 13, 2021 at 10:48

It can help out partially . System -> Settings -> Assistive Technologies; then Keyboard Accessibility, under "Mouse Buttons"

Also using Shortcuts may help you too.

another way is using ctrl-shift-numlock that is supposed to be the key combo that will let you move the cursor with the keyboard. But, I can't very sure that it works, since my laptop doesn't have a dedicated numlock key. you can control the mouse from keyboard. Keys / and * on the numpad select left mouse click and right mouse click respectively. Mouse click is done by 5 on the numpad.


In Ubuntu 11, Gnome I found this in System -> Preferences -> Keyboard and then Mouse Keys tab and check Pointer can be controlled using keypad.

To access System menu use ALT+F1 shortcut.


For Ubuntu users you can try:

  1. System-settings
  2. Universal Access
  3. Pointing and Clicking tab
  4. Switch off the key that says Mouse keys.

I also wanted to control the mouse from the keyboard, but with a different set of actions for keys. I implemented this functionality with a little utility program that I've put up on GitHub:


  • Neat, thank you for sharing! that's a really clever solution, and I much appreciate the flexibility of the code Mar 28, 2022 at 21:37
  • Nice little program :) Aug 15, 2022 at 14:27
  • Would it be more convenient to use a special key to toggle into mouse mode and then use arrow keys, etc, to control the mouse? Aug 18, 2022 at 11:32

You may also check mouseless


It works in all Linux distributions, even those running with Wayland.

It is the successor of xmouseless, which depended on X11 and had some minor issues.


  • move the pointer continuously
  • change the pointer speed on the fly
  • click, grab, scroll
  • remap keys
  • define arbitrary layers


  • execute arbitrary commands

Ubuntu 23.10 ships with this feature by default. Open Settings, navigate to Accessibility, then Pointing and Clicking, and enable Mouse Keys.

Screenshot that says: Mouse Keys: Use numeric keypad to move your mouse pointer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .