Consisting of keys that act as electrical switches, keyboards play an important role in the function of computers and other devices. When connected to a computer or device, a keyboard serves as a peripheral for input. You can perform commands on the computer by pressing the keys. While all keyboards serve this same basic function, though, there are many different types available, including mechanical and optical. So, what’s the difference between a mechanical keyboard and an optical keyboard?

What Is a Mechanical Keyboard?

Mechanical keyboards are characterized by the use of individual moving parts for their electric switches. Each key features an electrical switch — and these switches are comprised of individual moving parts. In a typical mechanical keyboard, each switch consists of a housing unit, a stem and a spring. When you press a key, the electrical contact underneath the key will push into a separate electrical contact below it, thereby completing the circuit. Releasing the key, on the other hand, causes it to spring back up, thereby breaking the circuit.

Although they are somewhat complex, mechanical switches have a long lifespan. They typically last longer than both membrane and dome-switch keyboards. Some mechanical keyboards, in fact, last for over 40 million clicks. Mechanical switches are also easy to repair. If a component breaks, you can replace it.

What Is an Optical Keyboard?

Also referred to as a photo-optical keyboard, an optical keyboard is a type of keyboard that’s characterized by the use of light. Optical keyboards are distinguished from all other types of keyboards, including mechanical keyboards, by utilizing light to detect keystrokes

Optical keyboards emit light below the surface of the keys. When you press a key on an optical keyboard, the light below the respective key will become obstructed. The optical keyboard will then detect this blockage as a keystroke.

Optical keyboards offer several benefits, one of which is resistance to moisture. Mechanical keyboards, unfortunately, are susceptible to moisture damage. If water or other liquids enters a mechanical keyboard, it may damage the individual switches below its keys. Thankfully, this isn’t an issue with optical keyboards. They are typically designed to protect against the intrusion of moisture. Optical keyboards also feature a slimmer design, making them ideal for small spaces.

Some people assume that optical keyboards are a modern invention, but this isn’t necessarily true. The technology was pioneered during the 1960s by American engineer Harley Kechner as a substitute for typewriter keys.