Move the mouse cursor with keyboard

Last Updated on May 6, 2019

You can use your keyboard for moving the mouse cursor in the X Window System. This means you can use the mouse without touching it at all.

Moving the cursor >

Of course you must have the X Window System running first… Then press Shift + NumLock to turn the feature on.

Move the mouse using the 1, 2, 3, 4, 6, 7, 8, and 9 keys in your number pad. Take a look at your number pad, and you’ll quite quickly figure out which key moves the mouse in which direction.

Clicking >

Click by hitting the 5 key on your number pad. Double click by hitting it twice.

Click and hold by hitting the 0 key. To release, hit 5.

By default, hitting the 5 key will do a left click. You can select what button to click with the /, *, and – keys on your number pad:
/ Left click
* Middle click
 Right click

Note that these just select the mouse button. You still need to use 5 to click it.

Ok, “left click” is a bad term because you can configure your mouse the way you want, but by “left click” I mean “the mouse behavior that occurs when most people using right-handed mouse click the left button.” You know what I mean, let’s not pick the nits here.

Turning the mouse feature off >

Press Shift + NumLock again to turn this feature off.