Learn — By WATMM Desk —
Key signatures explained for producers: read one, and know what it leaves out
A key signature is the set of sharps or flats at the start of a staff. This guide shows how to read one in seconds, why it names two keys not one, and what the MIDI key signature field can and cannot say. Sources checked on 1 Nov 2026.
Key facts
- Wikipedia says a key signature can hold up to seven sharps or up to seven flats, added in a fixed order: F, C, G, D, A, E, B for sharps and B, E, A, D, G, C, F for flats.
- In a sharp key the major tonic is a semitone above the last sharp; with more than one flat it is the second-to-last flat (Wikipedia).
- A relative minor shares its major key's signature and sits a minor third lower, while a parallel minor shares the tonic and has a different signature (Wikipedia; Open Music Theory course notes).
- Open Music Theory course notes say key signature changes do not always mark a change of tonic: keys are defined more by the tonic and dominant relationship in the music.
- A MIDI key signature meta event stores a count from -7 flats to 7 sharps and a major or minor flag, so it can represent 30 keys, per a MIDI.org forum answer.
Open a score, a lead sheet or a MIDI file from a collaborator and the first thing after the clef is a small cluster of sharps or flats. Most producers skim past it. It is worth thirty seconds, because it is the quickest way to learn which notes a part will lean on before you hear a single one.
What it actually is
A key signature is a set of sharps or flats written at the start of each staff so you do not have to mark every affected note. Wikipedia says it can hold up to seven sharps or up to seven flats (Wikipedia). Counting the empty signature, that gives the 15 "standard" key signatures the same article describes.
The sharps and flats always arrive in the same order. Sharps: F, C, G, D, A, E, B. Flats: B, E, A, D, G, C, F, which is the sharp order backwards (Wikipedia; the course notes at intmus.github.io give the same lists and the same backwards rule). Because the order is fixed, a signature with three sharps is always F, C and G sharp. You never have to search for which ones.
Reading one in five seconds
Sharps: go up a semitone from the last one. Wikipedia puts it as the tonic of a major key sitting "a semitone above the last sharp" in the signature. Three sharps end on G sharp, so the key is A major. Two sharps end on C sharp, so it is D major.
Flats: take the second-to-last. With more than one flat, the major tonic is the note of the second-to-last flat; one flat on its own is F major (Wikipedia). Three flats are B flat, E flat, A flat, so the second-to-last is E flat: E flat major.
Run those against a few signatures and the habit sticks quickly. It is faster than counting round a circle of fifths, though the two give the same answer. Our guide to the circle of fifths covers that map and what else it is good for.
It names two keys, not one
Here is the part that matters most for working producers. The signature does not tell you the key. It tells you a major key and its relative minor, because those two share a signature. Wikipedia says the relative minor is always a minor third below its major (Wikipedia). Three sharps could be A major or F sharp minor. Three flats could be E flat major or C minor.
The course notes make the contrast with the other kind of minor: a relative minor has a different tonic and the same signature, while a parallel minor has the same tonic and a different signature (course notes). C major and C minor are parallel; C major and A minor are relative. Mixing those up is the most common slip when someone describes a key by ear.
The same notes also say a signature is not a promise about the whole piece. Changes in tonic "aren't always represented by a key signature change", and keys are defined more by the tonic and dominant relationship in the music. In practice this means a song can wander through several keys under one unchanged signature, and a signature that never changes tells you where the notation started, not where the song lives.
To decide between the two candidates, listen for where the part rests. The first and last chords, and the note a bass line keeps returning to, usually settle it. That method is our own working advice, not a rule either source states.
Why there are 15 signatures but twelve keys
Seven sharps, seven flats and none make 15 signatures, but a keyboard only has twelve different major keys. Some signatures are the same pitches spelled two ways. Wikipedia notes that the seven-sharp and seven-flat signatures are usually notated as their enharmonic equivalents, so C sharp major is usually written as D flat major, which has five flats (Wikipedia). Subtracting the three duplicated pairs from 15 gives twelve; that count is our arithmetic, not a figure the page prints.
For a producer the spelling matters because it changes how a part reads. Five flats are far easier to read than seven sharps. When you export notation, pick the spelling a player would rather read.
What the MIDI key signature field can say
Standard MIDI files carry a key signature event too, and it is a handy mirror of everything above. A MIDI.org forum answer describes its two fields: a count running from -7 for seven flats through 0 for C to 7 for seven sharps, and a flag of 0 for major or 1 for minor (MIDI.org forum). The same thread points out that negative counts are stored in two's complement form, as byte values 255 down to 249, and that the event can therefore represent only 30 keys: 15 signatures times two modes.
Note the source here: this is a community forum thread quoting the specification, not a page from the specification itself, so treat the details as a good guide and check your own DAW's export if it matters.
The consequence is our own analysis. Because the flag only allows major or minor, a track in D Dorian cannot be described faithfully. You would label it either C major or D minor and accept that it is slightly wrong. If you are tagging stems for a collaborator, write the real mode in the file name and treat the MIDI event as a hint.
Our view
Learn the two shortcuts, last sharp up a semitone and second-to-last flat, and stop there. Memorising all 15 signatures is time better spent playing. What pays off is the habit of reading a signature as a shortlist of two keys and then letting the music pick one.
We would also argue against fighting your DAW over signatures. For electronic music that never reaches a printed page, the key signature field is bookkeeping. The notes in the piano roll carry the key, and your scale-snapping tool carries the rest. Write signatures properly when a human has to read them, and otherwise let them be a label. Our guides to scales and modes and reading sheet music for producers cover the next step in each direction.
Related reading: the circle of fifths, scales and modes, harmonic mixing and key detection.
Sources
- Keys (Intermediate Music Theory course notes, drawing on Open Music Theory), Intermediate Music Theory course (primary source). Accessed 1 Nov 2026.
- Key signature, Wikipedia. Accessed 1 Nov 2026.
- Only 14 key signature allowed in MIDI (forum thread), MIDI.org community forum. Accessed 1 Nov 2026.
Researched with AI assistance, written and checked by WATMM Desk.