A key signature is the set of sharps or flats written at the start of a staff, just after the clef, that holds for the whole piece and tells you which key it is in. It is a piece of shorthand. Rather than mark a sharp or flat on every note that needs one, the signature states them once, up front, and they apply from there on. Learn to read it and you can name a key at a glance and stop writing the same accidental over and over.
Plain theory, no instrument required. It reads the same on a piano, a guitar, or in a piano roll, in any key and any style.
A key signature is the set of sharps or flats written at the start of a staff, just after the clef, that applies to the whole piece and tells you which key it is in. It sits before the first note and quietly governs everything after it.
Its job is to save work. Most keys need certain notes raised or lowered every time they appear, and marking that on each note would clutter the page. So the signature declares it once: put a single sharp on the F line at the head of the staff and you have said, up front, that every F in the piece is played as F#, without another mark. A temporary accidental can still override it for a note or a bar, but the signature is the standing instruction.
The signature is really the written form of the key, not a separate idea. Which sharps or flats appear comes straight from the scale the music is centred on, so a key signature is best read alongside what a key actually is. If that groundwork is shaky, our guide to scales and keys covers the notes a key is built from; this guide is about how that choice gets written down.
A key signature works by naming, once, the notes that are always raised or lowered, so every note of that letter is played sharp or flat throughout unless an accidental says otherwise. The number of sharps or flats is fixed for each key, because it is exactly what that key needs to keep its scale pattern.
C major is the plain case: it needs no sharps or flats at all, so its signature is empty. Move to G major and one note has to be raised to hold the major shape, so its signature is a single sharp, F#. Each further key adds another, as the table shows.
| Key | Sharps or flats | The notes |
|---|---|---|
| C major | none | none |
| G major | 1 sharp | F# |
| D major | 2 sharps | F#, C# |
| F major | 1 flat | Bb |
| Bb major | 2 flats | Bb, Eb |
So a piece in D major has two sharps standing at the head of every line, F# and C#, and you play every F and every C a semitone higher without a single extra mark. A piece in Bb major has two flats, Bb and Eb, lowering every B and every E the same way. That is the whole mechanism: a short list at the front doing the job of hundreds of accidentals.
A key signature does not, on its own, pin down a single key. Each one is shared by a major key and its relative minor, the two keys that use the same notes. No sharps or flats is C major or A minor; one sharp is G major or E minor; two flats is Bb major or G minor. The signature tells you the pool of notes, and which note the music treats as home tells you which of the two you are actually in.
Sharps and flats are not added at random. They follow a fixed order, and it is worth knowing
because it is the same in every key and it makes the next section quick. Sharps are added in the
order F C G D A E B. Flats are added in the reverse of that, B E A D G C F.
Read it as a build-up. The first sharp key adds F#; the next keeps F# and adds C#; the next keeps both and adds G#, and so on down the list, each key holding all the earlier sharps and adding the next one along. Flats grow the same way from the other end: the first flat key adds Bb, the next adds Eb, the next Ab, following B E A D G C F.
| Count | Sharps, in order | Flats, in order |
|---|---|---|
| 1 | F# | Bb |
| 2 | F#, C# | Bb, Eb |
| 3 | F#, C#, G# | Bb, Eb, Ab |
| 4 | F#, C#, G#, D# | Bb, Eb, Ab, Db |
Because each new key in the sequence adds exactly one more sharp or one more flat in this order, the whole family of signatures can be laid out as a loop. That loop is the circle of fifths, the map that arranges these signatures by how many they carry; a key signature is one position on it.
There are two quick tricks that read the major key straight off the signature, so you rarely have to count anything out. One is for sharp keys and one is for flat keys, and both take a second once you know them.
For sharps, the last sharp sits one semitone below the home note, so take the last sharp written and go up a semitone. One sharp ends on F#, and a semitone above F# is G, so it is G major. Two sharps end on C#, and a semitone above is D, so it is D major. Three sharps end on G#, a semitone above is A, so it is A major. The last sharp is always the note just below the key you are in.
For flats, it is even shorter: the second-to-last flat names the key. Two flats are Bb and Eb, and the second to last is Bb, so it is Bb major. Three flats are Bb, Eb and Ab, and the second to last is Eb, so it is Eb major. The name is sitting right there in the signature.
| Signature | Trick | Major key |
|---|---|---|
| 1 sharp (F#) | F# up a semitone | G major |
| 2 sharps (F#, C#) | C# up a semitone | D major |
| 2 flats (Bb, Eb) | second-to-last flat | Bb major |
| 3 flats (Bb, Eb, Ab) | second-to-last flat | Eb major |
Two cases fall outside the tricks and are simply worth learning: no sharps or flats is C major, and one flat on its own (Bb) is F major, since with a single flat there is no second-to-last one to point at. And remember the tricks name the major key only. Every signature also belongs to a relative minor a minor third below that major, sharing the same notes, so once you have the major name the minor is the same signature read from a different home note.
We built ARGISH to make a key signature audible. It is a self-playing chord synth that locks to whatever key you choose, so every note it plays fits that key signature, without you marking a single sharp or flat or reading a staff at all. Pick a key and a mood and it writes chords and whole progressions that stay inside it, which is the quickest way to hear what a signature actually commits the music to, and to feel the difference between one key and the next by ear.
It runs free in your browser to try, and installs as AU, VST3, AAX or a standalone app when you want it inside your own sessions.
We write these when there is something worth writing down. One email when a new one lands or a new Tunary instrument ships. No newsletter, no schedule.