TECHNICAL GUIDE

Handwiring
Guide

Master the art of building custom keyboards from scratch without PCBs

Handwiring is the traditional method of building custom mechanical keyboards without PCBs. This technique gives you complete control over your keyboard's layout, switch choices, and functionality while teaching you the fundamentals of keyboard electronics.

01

Tools & Materials

  • Soldering iron (temperature controlled, 60W recommended)
  • Solder (60/40 or 63/37 tin/lead or lead-free)
  • Wire (22-26 AWG solid core for columns, stranded for rows)
  • Diodes (1N4148 through-hole diodes)
  • Microcontroller (Pro Micro, Elite-C, or similar)
  • Wire strippers and cutters
  • Multimeter for testing continuity
02

Understanding the Matrix

A keyboard matrix connects switches in rows and columns to reduce the number of microcontroller pins needed. Each key sits at the intersection of a row and column wire, with a diode preventing ghosting.

Key Principle: For an N-key keyboard, you need √N rows × √N columns instead of N pins.
03

Planning Your Layout

  • Design your keyboard layout using keyboard-layout-editor.com
  • Calculate the matrix dimensions (rows × columns)
  • Map out which switches connect to which pins
  • Draw a wiring diagram before starting
  • Test fit all switches in your case/plate
04

Wiring the Columns

Start by wiring all columns using solid core wire:

  • Strip and tin the wire ends
  • Solder wire to the top pin of each switch in a column
  • Keep wire runs straight and taut
  • Use helping hands or tape to hold wires in place
  • Test continuity after each column
05

Adding Diodes

Solder a diode to each switch before wiring rows:

  • Bend diode legs to fit between switch pins
  • Black band (cathode) faces the column wire
  • Solder one leg to the bottom switch pin
  • Leave the other leg extended for row wiring
  • Trim excess diode legs after soldering
Important: Diode orientation is critical! All diodes in a row must face the same direction.
06

Wiring the Rows

Connect all diodes in each row:

  • Use stranded wire for easier routing
  • Strip small sections of insulation at each diode
  • Solder wire to the extended diode legs
  • Route wires neatly beneath columns
  • Test each row for continuity
07

Connecting the Microcontroller

  • Plan pin assignments before wiring
  • Solder row wires to designated row pins
  • Solder column wires to designated column pins
  • Keep wire runs organized and labeled
  • Add strain relief with hot glue if needed
  • Double-check all connections with multimeter
08

Firmware & Testing

Flash and test your keyboard:

  • Configure QMK firmware with your matrix layout
  • Define row and column pins in config.h
  • Create your keymap
  • Flash firmware to microcontroller
  • Test each key using keyboard testing software
  • Debug any non-working keys (check solder joints)

Pro Tips

Clean Soldering

Use flux and keep your iron tip clean. Good solder joints are shiny and smooth, not dull or blobby.

Test As You Go

Test continuity after completing each row and column. It's easier to fix issues early than to debug later.

Color Coding

Use different colored wires for rows and columns. This makes troubleshooting much easier.

Documentation

Take photos during the build and keep your wiring diagram. Future you will thank present you.