Share Your Mouse and Keyboard Across Devices on Your Local Network
Ever find yourself constantly switching between a personal laptop and a work machine on your desk? Maybe you have a powerful desktop for coding but need to quickly check something on a less powerful notebook. Juggling multiple keyboards and mice is a clunky, frustrating experience that breaks your flow.
What if you could use a single mouse and keyboard to control every computer on your local network? That’s the exact problem lan-mouse
solves. It’s a neat, open-source tool that lets you seamlessly share your input devices across multiple machines.
What It Does
In a nutshell, lan-mouse
consists of two components: a server and a client. You install the server on the machine that has the physical mouse and keyboard you want to share. Then, you run clients on all the other devices you want to control. The server broadcasts your mouse movements and keystrokes over your local network, and the clients receive them, translating those actions into input on their respective machines.
Why It's Cool
While there are other software KVM (Keyboard-Video-Mouse) solutions out there, lan-mouse
stands out for a few reasons.
Its simplicity is a major feature. It’s a lightweight project focused on doing one job well, without a complicated setup or a bloated feature set. It’s written in Python, making it cross-platform and easy for developers to inspect, modify, and contribute to. The fact that it works over your existing LAN without requiring a complex configuration is a huge win for simplicity and security—your data isn’t bouncing off some external server.
For developers, the use case is perfect. You can easily drag your mouse from your primary development environment to a secondary machine running a database, a mobile simulator, or a test environment without ever touching another piece of hardware. It just feels like you’ve added another monitor, but for a completely different computer.
How to Try It
Getting started with lan-mouse
is straightforward. You’ll need Python installed on all machines involved.
-
Grab the code: Clone or download the repository from GitHub.
git clone https://github.com/feschber/lan-mouse.git
-
Install dependencies: Navigate into the cloned directory and install the required Python packages.
cd lan-mouse pip install -r requirements.txt
-
Run the server: On the machine with your physical mouse and keyboard, run:
python server.py
-
Run the client: On any other machine you want to control, run the client. It will automatically discover the server on the network.
python client.py
And that’s it! Your mouse should now be able to move between screens, controlling the other machine. You can find more detailed instructions and configuration options on the project’s GitHub repository.
Final Thoughts
lan-mouse
is a fantastic example of a practical tool that solves a real, everyday annoyance for developers and power users. It’s not overly complicated, it’s open for tinkering, and it just works. For those moments when you need to quickly interact with another machine on your network, it eliminates friction and keeps you in the zone. It’s definitely worth a try if you’ve ever thought, "I wish I could just drag my mouse over there."
—
Follow us for more cool projects: @githubprojects