v@@VERSION@@What's new

Control your mouse with your keyboard

Point, click, drag, and scroll without leaving the keyboard. Currently supports Sway on Wayland.

How it works

Point anywhere in a few keystrokes

A labelled grid covers the screen. Type a cell's label, then press an action key.

  • AltSpaceOpen the grid
  • a to zSelect a cell
  • sdfLeft, middle, or right click

Zoom in on small targets

Press Return to split the selected cell into a finer grid, shown in an optional magnifying lens.

  • ReturnRefine the selection
  • BackSpaceGo back a level
  • cDouble-click

Move, drag, and scroll

Mouse mode moves the pointer while a direction key is held, with smooth acceleration. Hold a button key while moving to drag.

  • hjklMove
  • sdfHold a button
  • ueyoScroll

Configure every detail

Keys, colours, grid density, and motion curves live in one TOML file. mousr reload applies changes without a restart.

Configuration reference

~/.config/mousr/config.toml
[grid]
refinement_zoom = 4.0
unmatched = "dim"

[motion]
curve = "ease-in-out"
initial_speed = 60.0
max_speed = 1800.0

[bindings.mouse]
left = "h"
down = "j"
up = "k"
right = "l"

Installation

Mousr currently supports Sway on Wayland only.

1Install

Or optionally use this helper script to install.

curl -fsSL https://mousr.toxdes.com/install | sh
Archives do not include runtime libraries.

Install libwayland-client0 and libxkbcommon0 on Debian/Ubuntu, wayland-libs and libxkbcommon on Fedora, or wayland and libxkbcommon on Arch.

2Configure Sway
~/.config/sway/config
exec mousr daemon

# Alt+Space: grid mode
bindsym Mod1+space exec mousr grid

# Alt+Shift+Space: mouse mode
bindsym Mod1+Shift+space exec mousr mouse
3Start Mousr

Apply the bindings and start the daemon in the current session. Later sessions start it from the exec line.

swaymsg reload && swaymsg exec mousr daemon

Press Alt Space to open the grid. See the configuration reference for settings.

Interactive demo

The demo runs the Mousr grid and motion logic in the browser.