KEasyKVM
Guide

How to switch your monitor's input with a keyboard shortcut

Last checked:

You don't have to reach for the buttons under the bezel. Nearly every modern monitor speaks DDC/CI, a VESA standard that lets software talk to the monitor over the video cable it's already plugged into. One of the things it can say is "show the other input." Here's how it works and the tools that do it.

The short answer

DDC/CI (Display Data Channel / Command Interface) carries small commands from your computer to your monitor over the existing HDMI, DisplayPort, or USB-C cable. The commands are defined by the VESA Monitor Control Command Set (MCCS), and VCP code 0x60 is Input Select. Write a value to it and the monitor switches to that input, exactly as if you'd pressed its physical buttons. So any software that can send that command can flip your monitor between two computers, and you can bind that to a keyboard shortcut.

That's the whole trick. The rest is choosing how you want to trigger it.

What actually travels over the cable

Every HDMI, DisplayPort, DVI and VGA connector carries a slow two-wire I2C bus alongside the video lanes. It is there so the computer can read the monitor's EDID at plug-in. DDC/CI reuses that same bus in the other direction: the computer writes a short packet to I2C address 0x37 and the monitor's scaler chip acts on it.

The packet that changes a setting is a Set VCP Feature request. It carries one feature code (0x60 in this case) and a two-byte value. MCCS defines no reply for it, so nothing reports success and nothing reports failure. The only way to find out what happened is to send a Get VCP Feature request for the same code afterwards and read the value back. The gap between "the command went out" and "the input changed" is where most DDC/CI trouble lives.

The capabilities string

A monitor will also tell you what it supports, if you ask. The capabilities string is a block of ASCII the monitor returns on request, listing its MCCS version, the VCP codes it implements and, for a non-continuous code like Input Select, the values it will accept. The relevant fragment looks like this:

The piece that matters is 60(0F 11 12): this panel claims Input Select and says it will take DisplayPort 1, HDMI 1 and HDMI 2. If 60 is absent from the list, the monitor is telling you it does not do input switching at all. If it is present, you have a starting point rather than a guarantee, for reasons the caveats below go into.

The input values

MCCS defines the values, so they are the same on most monitors:

Reading 0x60 back with each input on screen gives you your own monitor's real numbering.

Option 1: The monitor's own buttons (free, clunky)

Every monitor ships with this: press the OSD buttons, navigate the on-screen menu, pick the input. It's free and it always works, but it means physically reaching under or behind the panel, and the menus on most monitors take four or five presses to get to the input list. Fine once a day; tedious if you swap between a work laptop and a desktop all day long.

Option 2: Free command-line tools and scripts (great for tinkerers)

Because DDC/CI is an open standard, there's a healthy ecosystem of free tools that can write VCP code 0x60. If one computer is all you need to move the screen from, one of these is probably the whole answer, and it costs nothing.

Linux: ddcutil

ddcutil is the reference implementation and the tool other projects get checked against. Four commands cover the job:

With more than one monitor attached, add --display 2 (numbering starts at 1, and the first display is used if you say nothing).

macOS: BetterDisplay, Lunar, m1ddc, ddcctl

BetterDisplay covers the most hardware, Intel Macs and built-in HDMI ports included. Its CLI addresses VCP codes by name or number:

m1ddc is a small command-line tool from the same author, Apple silicon only. Use m1ddc display list to find the display number, then m1ddc display 1 set input 17 to switch to HDMI 1. It takes decimal here: 15 is DisplayPort 1, 17 is HDMI 1, 27 is USB-C. Its get command covers luminance, contrast, colour gains and volume but not input, so you cannot read the input back with m1ddc alone, and some LG panels need set input-alt with a different set of values.

Lunar also does input switching and exposes it to both its CLI and macOS Shortcuts, which is the quickest route to a hotkey without writing code. ddcctl still works (ddcctl -d 1 -i 17 sets display 1 to HDMI 1) and is the usual answer on older Intel Macs, though its author describes the project as being in maintenance mode.

One correction, because it comes up constantly: MonitorControl does not switch inputs. Brightness, volume and contrast over DDC is the whole feature list.

Windows: ControlMyMonitor, ddcswitch

NirSoft's free ControlMyMonitor is a single executable with no installer. It shows every VCP code the monitor reports and can be driven from a batch file or a shortcut:

ddcswitch is a newer open-source option with a friendlier interface. ddcswitch list shows every DDC/CI-capable monitor and its current input, ddcswitch get 0 input reads one back, and ddcswitch set "LG ULTRAGEAR" HDMI2 switches by monitor and input name rather than raw hex.

Putting it on a key

None of these tools bring a hotkey of their own, so you supply one:

The free route is a real route, and worth taking if you enjoy this sort of thing. What you take on is the assembly: finding your monitor's input values, writing the script, binding the key, then doing it again on the second computer. The other limit is shared by every tool on this page. They move the picture only. After the switch your keyboard and mouse are still attached to the computer you just switched away from, so you need a USB switch, a second set of peripherals, or keyboard-sharing software alongside them.

Option 3: EasyKVM (one hotkey, and your keyboard follows)

EasyKVM is a software KVM switch for Mac and Windows built around exactly this DDC/CI trick, plus the part the scripts leave out. Press a global hotkey (default Ctrl+Alt+Q, works from either machine) and it switches the monitor's input over DDC/CI and hands your keyboard, mouse, and audio to the other computer over your LAN. Press it again to come back. No input values to look up, no scripts to maintain, no USB switch.

  1. Install EasyKVM on both computers (macOS 13+ and Windows 10/11).
  2. Pair them once with a 6-digit code over your LAN. No account needed.
  3. Plug each computer into its own input on the monitor (HDMI, DisplayPort, or USB-C).
  4. Press the hotkey. The monitor flips, and your keyboard and mouse now drive the other machine.

The parts that take longest to get right by hand are handled in the background. It reads the input back after writing it instead of assuming the write landed, translates the private input numbering used by some MSI panels, and when the monitor will only take commands from the input it is currently showing, asks the computer that is on screen to perform the switch.

Caveats: read before you rely on DDC/CI

DDC/CI input switching works on most modern monitors, but not all, and the failure modes are specific enough to be worth knowing before you blame a cable.

It is often switched off, and it can switch itself back off

Plenty of panels ship with DDC/CI disabled. It is usually a single line in a settings or OSD submenu, labelled "DDC/CI" or sometimes "Smart Control". This is the most common reason nothing happens.

The version that wastes an afternoon: on some monitors the setting does not survive a loss of power. Use a switched socket or pull the plug overnight and the monitor comes back with DDC/CI disabled again. If switching worked yesterday and does nothing today, check the menu first.

Only the input on screen is listening

Most panels accept DDC/CI commands only on the input they are currently displaying. The other input's I2C channel is physically there, but the scaler ignores what arrives on it.

That makes the two directions of a swap completely different problems. Switching away is easy: the machine sending the command is the one on screen. Switching back is the hard direction, because the machine you want to return to sits on an input the monitor has stopped paying attention to. The fix is to send the command from whichever machine is currently on screen, which means the two computers need a way to talk to each other.

Some monitors don't use the values they advertise

The capabilities string is a claim, not a contract. Several MSI monitors built on MStar scalers list the standard Input Select values and then use a private numbering internally: HDMI 1 is 0x05, HDMI 2 is 0x06, DisplayPort 1 is 0x07, DisplayPort 2 is 0x08. Write the standard 0x11 for HDMI 1 to one of these and the monitor takes the command without complaint and does nothing with it.

If your monitor reports Input Select, appears to accept writes, and never moves, try the low values before concluding the feature is missing.

An acknowledged command is not a completed command

Because Set VCP Feature has no reply, a tool that reports success is usually reporting only that it managed to write to the I2C bus. Every problem above looks identical from the sending side: a clean write and a screen that does not change. Reading 0x60 back after the write is the only check that means anything.

Cables, docks and timing

If your monitor turns out not to support input switching, EasyKVM still works as a keyboard + mouse + audio switch. Turn off "Swap monitor input on hotkey" and change the input yourself. The troubleshooting page covers the common DDC/CI failure modes in more detail.

FAQ

Does my monitor support DDC/CI input switching?
Probably, but the only way to be sure is to try. Almost every monitor made after ~2015 speaks DDC/CI, and if yours has on-screen menu buttons it almost certainly does. Input switching specifically (VCP code 0x60) is a separate question, though. A monitor can accept brightness commands over DDC/CI and still ignore input-switch commands. A free tool like ddcutil (Linux), ControlMyMonitor (Windows), or BetterDisplay (macOS) will tell you in minutes, and so will EasyKVM's 3-day trial.
Can I switch monitor input without a KVM switch?
Yes. DDC/CI runs over the video cables you already have, so no extra hardware is needed. Free command-line tools and scripts can send the input-switch command, and EasyKVM binds it to a global hotkey and also hands your keyboard, mouse, and audio to the other computer at the same time: the full KVM result, in software.
Does this work on both Mac and Windows?
The hotkey works on both. You can press it from the Mac or the PC. A Mac + Windows desk swaps the monitor automatically no matter which side you press the hotkey on.
Why isn't my monitor switching?
Three common causes. First, DDC/CI is turned off by default in some monitors' on-screen menus. Look for a "DDC/CI" or "Smart Control" setting and enable it. Second, USB-C docks and hubs sometimes eat the DDC/CI signal; try a direct DisplayPort or HDMI cable to confirm. Third, a few monitors simply don't accept input-switch commands even when other DDC/CI controls work. Also note panels can take a moment to actually change input after the command is sent. More fixes on the troubleshooting page.
Why can I switch away from a computer but not back to it?
Because most monitors only accept DDC/CI commands on the input they are currently displaying. Switching away works, since the machine sending the command is the one on screen. Switching back has to come from a machine whose input the monitor has stopped paying attention to, so a script on one computer often works in one direction and looks broken in the other. The fix is to have whichever computer is on screen send the command, which means the two machines need a channel between them. EasyKVM does that over the LAN.
My monitor accepts the command but the input doesn't change. Why?
A Set VCP Feature request has no reply defined in the protocol, so a tool reporting success is often only reporting that the write reached the monitor. Three things produce a clean write and a screen that does not move: DDC/CI disabled in the on-screen menu, a command sent from an input the monitor is not displaying, and a monitor using private input values instead of the standard ones it advertises. Some MSI panels on MStar scalers are in that third group, where HDMI 1 is 0x05 rather than 0x11. Reading code 0x60 back after writing it tells these apart.
What is VCP code 0x60?
It's the "Input Select" control in the VESA Monitor Control Command Set (MCCS), the standardized list of things software can ask a monitor to do over DDC/CI. Writing a value to code 0x60 tells the monitor which input to display: each HDMI, DisplayPort, and USB-C port has its own value. It's the same switch the monitor's physical buttons flip, just triggered over the video cable instead.
Can I switch monitor input without pressing the buttons?
Usually, yes. Almost every monitor made after ~2015 speaks DDC/CI, the control channel inside the HDMI, DisplayPort or USB-C cable, and writing a new value to VCP code 0x60 changes the input on most of them. Free tools such as ddcutil (Linux), BetterDisplay or m1ddc (macOS) and ControlMyMonitor (Windows) send that command from the computer. DDC/CI may need to be switched on in the monitor's on-screen menu first.
How do I swap the monitor between two computers with one key?
Plug each computer into its own input on the monitor and bind a key on each machine to the DDC/CI input-switch command, for example Hammerspoon calling m1ddc on a Mac or AutoHotkey calling ControlMyMonitor on Windows. Most monitors only take the command from the input on screen, so each computer's key should switch to the other computer's input. That moves the picture only, and your keyboard and mouse stay with the first computer unless a USB switch moves them too. EasyKVM ($29.99 once) does both on one hotkey: it switches the input and hands the keyboard, mouse, and audio to the other computer over the LAN.

Try it on your own monitor

The fastest way to find out whether your monitor plays along is to run the 3-day trial: no credit card, full functionality, and it tells you within minutes whether DDC/CI input switching works on your exact panel. If it doesn't, there's a 14-day no-questions refund.

Start the free 3-day trial Buy EasyKVM — $29.99 once

One-time payment · 3-day free trial · 14-day refund, no questions