General MIDI Program Numbers: 1–128 or 0–127?
General MIDI counts instruments from 1. The byte in the file counts from 0. Most confusion comes from mixing the two.
General MIDI (GM), published in 1991, fixed a list of 128 instruments so that a file made on one device would play with sensible sounds on another. Program 1 is Acoustic Grand Piano, program 25 is Acoustic Guitar (nylon), program 41 is Violin and program 128 is Gunshot.
Two ways to count
The General MIDI list numbers the instruments from 1 to 128. Inside a MIDI file, the Program Change message carries a single data byte from 0 to 127. So Violin is program 41 in the list and value 40 in the file.
Software does not agree on which number to show. Many sequencers and keyboards show 1 to 128; programming libraries, MIDI monitors and some trackers show 0 to 127. If an instrument comes out one step wrong, for example a Bright Acoustic Piano instead of a grand, the two systems have been mixed. Every instrument page on this site shows both numbers and the hexadecimal byte.
What the message looks like
A Program Change is two bytes. The first is C0 to CF, which says “Program Change” and gives the channel (C0 is channel 1, C9 is channel 10, CF is channel 16). The second is the program value. Switching channel 1 to Flute (program 74, value 73) is C0 49 in hexadecimal.
The 16 families
The 128 instruments come in 16 families of eight: piano, chromatic percussion, organ, guitar, bass, strings, ensemble, brass, reed, pipe, synth lead, synth pad, synth effects, ethnic, percussive and sound effects. The family tells you roughly what to expect even when the exact sound differs between devices.
Channel 10 and drums
General MIDI reserves channel 10 for percussion. A Program Change on that channel does not choose an instrument from the list; each note number plays a different sound, such as 36 for the bass drum and 38 for the snare. The drum kit map lists notes 35 to 81.
Bank Select, GS and XG
Roland GS, Yamaha XG and General MIDI 2 add hundreds of extra sounds. They reach them with Bank Select controller messages (controllers 0 and 32) sent before the Program Change. A plain General MIDI player, like the one on this site, ignores the bank and plays the standard instrument with the same program number, so a file written for GS or XG still plays, with the nearest standard sound.
Changing an instrument
To switch a track to a different instrument without a sequencer, open the file in the instrument changer, pick the new instrument and download the result.