ThisCalculator

Everyday

Ubuntu Mouse & Touchpad Speed: Set Pointer Motion

Updated · Standard formula, shown below

Ubuntu Mouse & Touchpad Speed: Set Pointer Motion

This guide explains how to correctly set mouse and touchpad pointer motion speed in Ubuntu, covering both the graphical settings and the underlying command-line tools. You will learn the exact steps to adjust sensitivity, acceleration, and related options, plus how to troubleshoot common issues where the settings don’t seem to stick.

Understanding Pointer Speed vs. Acceleration

Ubuntu (like most Linux distributions) separates pointer motion into two distinct concepts: speed (sensitivity) and acceleration. Speed is a constant multiplier applied to the raw movement of the device. Acceleration changes that multiplier based on how fast you move the pointer — a quick flick moves the cursor farther than a slow drag of the same physical distance. The graphical settings in Ubuntu’s Settings app combine these into a single slider, but the underlying system uses separate values. Knowing this distinction matters because a common complaint — “my mouse feels too fast but also imprecise” — usually comes from acceleration being too high, not speed.

Graphical Settings: The Easy Way

For most users, the Settings app is sufficient. Open Settings from the system menu (or search for it), then go to Mouse & Touchpad. You’ll see a slider labeled Mouse Speed (or Pointer Speed). Moving it left reduces speed, right increases it. The same slider applies to both mouse and touchpad if both are present, but you can adjust each independently by selecting the device tab at the top of that section.

One important detail: the graphical slider only sets the speed (the constant multiplier). It does not expose acceleration settings. If you need to adjust acceleration, you must use the command line or a third-party tool. Also note that the slider’s range is not linear — the default value is not necessarily “1.0” in the underlying system; it maps to a specific libinput setting that may vary by Ubuntu version.

Command-Line Control: xinput and libinput

To see the actual numeric values, open a terminal and use xinput. First, list your input devices:

  1. Run xinput list to find your mouse or touchpad’s ID number (e.g., “Logitech USB Optical Mouse” id=11).
  2. Run xinput list-props 11 (replace 11 with your ID) to see all properties.
  3. Look for libinput Accel Speed (range -1 to 1) and libinput Accel Profile Enabled (two boolean values: adaptive and flat).

To set speed, use: xinput set-prop 11 "libinput Accel Speed" 0.5 (values between -1 and 1). To disable acceleration entirely (set to “flat” profile), use: xinput set-prop 11 "libinput Accel Profile Enabled" 0, 1. The first number is adaptive (0 = off), second is flat (1 = on). If you prefer a constant speed without acceleration, this is the correct setting.

Making Changes Permanent

Changes made with xinput are temporary — they reset when you log out or reboot. To make them permanent, you have two reliable options:

  • Startup application: Add a command like xinput set-prop 11 "libinput Accel Speed" 0.5 to your startup applications (search for “Startup Applications” in the system menu). This runs every time you log in.
  • Configuration file: Create a file in /etc/X11/xorg.conf.d/ (e.g., 50-mouse.conf) with a matching device section. This is more robust but requires root access and knowledge of your device’s identifier.

Be aware that the device ID (11 in the example) can change if you plug/unplug devices. To avoid this, use the device name in a script that finds the ID dynamically, or use the xorg.conf approach which matches by name.

Common Problems and Fixes

Many users report that the Settings slider “does nothing” or that changes revert. Here are the most frequent causes and solutions:

  • Multiple devices with same name: If you have both a mouse and a touchpad, they might share a similar name. Check xinput list carefully; you may be setting the wrong device.
  • Wayland vs. X11: If you’re on Wayland (default in recent Ubuntu), xinput may not work for all devices. Try gsettings instead: gsettings set org.gnome.desktop.peripherals.mouse speed 0.5 (range -1 to 1). For touchpad, replace mouse with touchpad.
  • Acceleration profile not applied: Some devices ignore the “flat” profile. Test with xinput list-props after setting to confirm it took effect. If not, try setting libinput Accel Profile Enabled to 1, 0 (adaptive only) — that’s the default and may be more compatible.
  • Settings app overrides: Any change made in the Settings app will overwrite your command-line settings. Avoid opening the Mouse & Touchpad panel after setting values manually, or re-apply your settings afterward.

Touchpad-Specific Options

Touchpads have additional settings beyond speed: natural scrolling, tap-to-click, and two-finger scrolling. These are all in the same Settings panel. For finer control, the command-line properties include libinput Natural Scroll Enabled, libinput Tap To Click Enabled, and libinput Scroll Method Enabled. For example, to disable tap-to-click: xinput set-prop 12 "libinput Tap To Click Enabled" 0 (replace 12 with your touchpad ID).

One common touchpad issue is “cursor jumps” — often caused by accidental palm contact. While there’s no built-in palm detection control in standard Ubuntu, you can reduce sensitivity (lower speed) or disable tap-to-click to minimize accidental clicks. For more advanced palm rejection, you may need to use a third-party tool like libinput-gestures or a custom xorg.conf, but these are beyond the scope of the basic settings.

Comparing with Windows/macOS

Users coming from Windows often find Ubuntu’s default mouse speed feels different. Windows uses a “pointer precision” (acceleration) option that is on by default; Ubuntu’s libinput also has acceleration enabled by default, but the curve is different. To mimic Windows behavior, you can set the acceleration profile to “adaptive” (default) and adjust speed to around 0.3–0.5. macOS users typically prefer “flat” (no acceleration) because macOS uses a constant speed by default. So the choice depends on your muscle memory, not on which is “better.”

Frequently Asked Questions

Why does my mouse speed reset after reboot?

Because xinput changes are not persistent. You need to add a startup command or create an xorg.conf file as described above. The Settings app changes are persistent, but they only cover the speed slider, not acceleration or profile.

How do I disable mouse acceleration completely?

Set the acceleration profile to “flat” using xinput set-prop <id> "libinput Accel Profile Enabled" 0, 1. This makes the pointer move at a constant speed regardless of how fast you move the mouse. You can verify with xinput list-props.

What is the difference between “speed” and “acceleration” in Ubuntu?

Speed is a constant multiplier — if you set it to 2.0, the pointer moves twice as far for the same physical movement. Acceleration is a dynamic multiplier that increases with the velocity of your movement. The Settings slider only controls speed; acceleration is managed by the profile (adaptive or flat).

My touchpad is too sensitive — how do I make it less responsive?

Lower the Mouse Speed slider in Settings. If that’s not enough, you can also disable tap-to-click (to avoid accidental taps) and reduce the pointer speed further using xinput with a negative value like -0.5. For persistent changes, use the startup command method.

Does the Settings slider affect both mouse and touchpad?

Yes, in the Mouse & Touchpad panel, there is a single slider that applies to the currently selected device (you can switch between mouse and touchpad tabs). However, the underlying libinput settings are per-device, so you can set different speeds for each via the command line.

Why does xinput not work on Wayland?

Wayland restricts direct input device control for security reasons. xinput works only under X11. On Wayland, use gsettings for speed, but note that acceleration profile control is not exposed through gsettings — you may need to switch to X11 session (choose “Ubuntu on Xorg” at login) for full control.

Related

Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.