InputSync lets you share the keyboard and mouse from one computer with other computers on the same local network.
Run the server on the machine with the keyboard and mouse. Then run a client on each machine you want to control. Input events are sent over TCP and encrypted with a shared token.
This is meant to stay small and easy to follow. It is not trying to replace Synergy, Barrier, or a full KVM setup. It does not auto-discover machines, switch screens when the pointer reaches an edge, or save profiles. The goal is a simple tool that is easy to install, read, and change.
- Python 3.9 or newer.
- Two or more computers on the same network.
- System permissions to read and control the keyboard and mouse.
On macOS, you will usually need to give Accessibility permissions to Terminal, Python, or the app in System Settings.
Clone the repository and enter the folder:
git clone https://github.com/DavidPerezA12/InputSync.git
cd InputSyncLinux/macOS:
chmod +x install.sh
./install.shWindows:
install.batManual setup:
python3 -m venv env
source env/bin/activate
python -m pip install -r requirements.txtOn Windows:
python -m venv env
env\Scripts\activate
python -m pip install -r requirements.txtFor development, install the project with its developer tools:
python -m pip install -e ".[dev]"On the computer that shares the keyboard and mouse:
INPUTSYNC_TOKEN="change-this-token" python servidor.pyBy default the server listens on all network interfaces so other computers on
your LAN can connect. If you want to bind it to a specific interface, pass
--host:
INPUTSYNC_TOKEN="change-this-token" python servidor.py --host 192.168.1.50On a client computer:
INPUTSYNC_TOKEN="change-this-token" python cliente.py --ip 192.168.1.50 --port 12345Replace 192.168.1.50 with the server IP address. The token must be the same on
both sides.
You can also pass the token with --token, but using an environment variable is
better because command-line arguments may be visible in the system process list:
python servidor.py --token "change-this-token"
python cliente.py --ip 192.168.1.50 --port 12345 --token "change-this-token"The default port is 12345. To use another one:
INPUTSYNC_TOKEN="change-this-token" python servidor.py --port 23456
INPUTSYNC_TOKEN="change-this-token" python cliente.py --ip 192.168.1.50 --port 23456If you want the client to keep trying when the server restarts or the connection drops:
INPUTSYNC_TOKEN="change-this-token" python cliente.py --ip 192.168.1.50 --reconnectIf you prefer a small window instead of the terminal:
python app_gui.pyThe GUI can start either the server or the client with the IP, port, and token
you enter. Logs are written in the project folder with names like
servidor_inputsync.log and cliente_inputsync.log. You can also stop the
processes started from the GUI.
InputSync encrypts messages with a key derived from the shared token using PBKDF2-HMAC-SHA256. Use a long, unique, randomly generated token. For example:
python -c "import secrets; print(secrets.token_urlsafe(32))"The default server bind address accepts connections from every local network interface. Only use InputSync on networks you trust, and do not expose its port to the Internet. It is not built to replace a hardened remote-access tool.
ModuleNotFoundError: install the dependencies withpython -m pip install -r requirements.txt.- The client connects but nothing moves: check Accessibility or input-control permissions.
Address already in use: the port is already taken. Stop the previous process or use another port.- It does not connect: check the server IP, firewall, and that both computers are on the same network.
- macOS does not capture the keyboard or mouse: reopen the terminal after granting permissions.
Run the tests:
python -m unittest discover -s testsCheck style and common errors:
python -m ruff check .
python -m compileall -q app_gui.py cliente.py servidor.py inputsync_protocol.py testsCheck installed dependencies:
python -m pip checkBuild and install locally:
python -m pip install -e .
inputsync-server --help
inputsync-client --help
inputsync-guiMIT. See LICENSE.