What happens when you move your mouse
A computer mouse works by detecting the direction and speed you move it, then sending that information to your computer 60 to 125 times per second. Inside the mouse is a small camera or light sensor that watches a tiny patch of the surface beneath it. As you slide the mouse, that sensor sees the surface move past and calculates how far and in which direction. Your computer reads those calculations and moves the cursor on screen to match.
The sensor does not care what surface you use — a mousepad, a desk, a book, even your leg. It straightforward compares what it sees now to what it saw a fraction of a second ago, the same way your eye can tell when something has shifted position. This is why a mouse works on almost any flat surface, and why it stops working if you lift it off the desk: the sensor has nothing to compare.
Key Takeaways
- A mouse uses an optical or laser sensor to watch the surface beneath it and detect movement by comparing what it sees from moment to moment.
- The mouse sends position data to your computer dozens of times per second, and your computer moves the cursor to match.
- Wireless mice use radio signals (usually 2.4 GHz) to send data to a receiver plugged into your computer, while wired mice send data through the cable.
- The left and right buttons are straightforward switches that close an electrical circuit when pressed, sending a click signal to your computer.
- The scroll wheel is a rotating encoder that counts how many notches you have turned it and sends that count to your computer.
Optical versus laser sensors
Most mice sold today use one of two types of sensors: optical or laser. An optical mouse has a small red or infrared LED (light-emitting diode) that shines on the surface below. A camera lens focuses the reflected light onto a sensor chip. That chip takes a photograph of the surface roughly 1,500 to 8,200 times per second, depending on the mouse model. The chip then compares each new photograph to the one before it and calculates how the surface has moved.
A laser mouse works the same way, except it uses a laser instead of an LED. The laser light bounces off the surface at a sharper angle, which means it can detect smaller details and finer movement. Laser mice are more sensitive and work on a wider range of surfaces, including some glossy or transparent materials that confuse optical mice. For most everyday use, the difference is small — both types move the cursor smoothly and respond when ready to your hand.
How the mouse sends data to your computer
A wired mouse sends its position data through the cable to your computer. The cable carries both power (so the mouse does not need a battery) and data signals. When you move the mouse, the sensor chip calculates the new position and sends it down the wire. Your computer receives the signal and updates the cursor location on screen.
A wireless mouse uses radio waves instead of a cable. Most wireless mice operate on the 2.4 GHz frequency, the same band used by Wi-Fi and Bluetooth. The mouse has a small transmitter inside that broadcasts its position data to a receiver — a small device plugged into a USB port on your computer. The receiver picks up the signal and passes it to your computer. Wireless mice need a battery or rechargeable power source because they cannot draw power from a cable. The radio signal travels only a short distance, usually 10 to 30 feet, which is why your mouse stops working if you move too far from your computer.
How mouse buttons register clicks
The left and right buttons on your mouse are mechanical switches. Underneath each button is a spring and a metal contact. When you press the button, the spring compresses and the metal contact touches another metal surface, completing an electrical circuit. That circuit closure is detected by the mouse's main chip, which when ready sends a "click" signal to your computer. When you release the button, the spring pushes it back up, the circuit breaks, and the mouse sends a "release" signal.
Your computer receives the click signal and passes it to whatever program is running. If your cursor is over a link in a web browser, the browser opens that link. If it is over a file in a folder, the computer selects that file. The mouse does not know or care what happens — it straightforward reports that a button was pressed and released. The speed of this process is nearly when ready: from the moment you press the button to the moment your computer registers the click is typically less than a millisecond.
How the scroll wheel works
The scroll wheel is a rotating encoder — a device that counts how many times it has turned. As you roll the wheel up or down, it spins a shaft inside the mouse. That shaft has notches or a pattern on it, and a sensor counts each notch that passes. The mouse sends the count to your computer: "the wheel turned 3 notches up" or "5 notches down." Your computer then scrolls the page or window by a corresponding amount.
The notches you feel when you scroll are intentional — they give you tactile feedback so you know the wheel is responding. Some mice let you adjust the scroll speed in software, which changes how far the page moves per notch. A few high-end mice have a "free-spin" mode where the wheel can rotate without notches, allowing faster scrolling, but most everyday mice use the notched design.
Why your mouse needs a mousepad (and when it does not)
A mousepad is not required for a mouse to work, but it can improve performance. The sensor in your mouse works best on surfaces with visible texture or detail — the tiny bumps and variations that the camera can use as reference points. A smooth, featureless surface like polished glass or a blank white desk can confuse the sensor because there is nothing for it to compare from moment to moment. A mousepad with a woven or printed texture gives the sensor plenty of detail to track.
Some surfaces are worse than others. A mirror or highly reflective surface can bounce the light in ways that blind the sensor. A very dark surface may not reflect enough light for the camera to see clearly. Most desks, tables, and plain paper work fine without a pad. If your mouse cursor jumps around or moves erratically, switching to a mousepad or a different surface is often the first fix to try.
What happens inside the mouse when you move it
Here is the sequence of events from the moment you move your mouse until the cursor moves on screen. You push the mouse forward. The optical or laser sensor takes a photograph of the surface. The sensor chip compares this photograph to the previous one and calculates that the surface has moved 5 pixels to the left (from the mouse's perspective). The chip converts this into a position update: "cursor should move 5 pixels to the right." This update is sent to your computer either through the cable or by radio signal. Your computer receives the update and tells the graphics card to redraw the cursor 5 pixels to the right. The graphics card updates the screen. All of this happens in about 8 to 16 milliseconds — fast enough that the cursor appears to follow your hand smoothly.
The mouse does not track absolute position — it does not know where on the desk it is. It only knows how much it has moved since the last update. This is why you can pick up your mouse, move it to a different part of the desk, and put it down without the cursor jumping. The sensor sees the desk surface disappear (because the mouse is in the air) and stops sending movement data. When you put the mouse down again, the sensor sees the desk surface reappear and resumes tracking.
Frequently Asked Questions
Why does my mouse cursor sometimes jump or freeze?
Cursor jumping usually means the sensor cannot see the surface clearly. Try cleaning the bottom of your mouse with a dry cloth — dust or debris can block the light. If you are using a wireless mouse, the batteries may be low, or the receiver may be too far from the mouse. Try moving closer to the computer or replacing the batteries. If the problem persists, try a different surface or mousepad.
Can I use a mouse on a glass table?
Glass is difficult because it is transparent and highly reflective. The light from the sensor passes through the glass or bounces at odd angles, so the camera cannot see a clear image. A mousepad placed on top of the glass will solve the problem. Some laser mice work better on glass than optical mice, but a pad is still the most reliable fix.
How often does a mouse send position data to the computer?
Most mice send updates between 125 and 1,000 times per second, depending on the model. Gaming mice often send faster updates (up to 8,000 per second) to reduce lag in competitive games. For everyday use, 125 updates per second is more than fast enough — you will not notice a difference.
Do wireless mice have lag compared to wired mice?
Modern wireless mice have almost no noticeable lag — the radio signal travels at the speed of light, and the delay is typically less than a millisecond. Older wireless mice or those with weak batteries may feel sluggish, but current models are as responsive as wired mice for normal use. Gaming mice are available in both wired and wireless versions.
What is the difference between a mouse and a trackpad?
A trackpad (like those on laptops) uses a touch sensor to detect your finger position instead of watching a surface below. Your finger slides across the pad, and the sensor tracks where your finger is at each moment. A mouse tracks movement of the device itself. Both send position data to the computer, but they sense movement in different ways.