Key Signature Calculator
Test cases replayed : 3 of 3 match · Methodology · No outside source listed
Choose a key to get its key signature and its relative key.
Result
Key signature
Sharps or flats, in the order written
- Relative key (same signature)
Estimate for planning only, not tax, legal, financial or medical advice. This calculator uses the method explained on this page.
This browser did not allow copying. The sentence is in the box below, already selected: copy it with your keyboard or the menu.
How to use this calculator
Fill in the fields in this order; each step takes you to its field.
- Key: choose one of the 30 options in the list.
- Read the result: Key signature; the panel also shows Sharps or flats, in the order written and Relative key (same signature).
How this calculator works
Key signatures follow the circle of fifths: each step up a fifth from C major adds one sharp (G, D, A, E, B, F♯, C♯ major) and each step down a fifth adds one flat (F, B♭, E♭, A♭, D♭, G♭, C♭ major).
Sharps are always added in the order F♯ C♯ G♯ D♯ A♯ E♯ B♯ and flats in the reverse order B♭ E♭ A♭ D♭ G♭ C♭ F♭.
A minor key shares the signature of the major key a minor third above it: A minor with C major, E minor with G major, C minor with E♭ major.
The formula
| Symbol | Meaning |
|---|---|
| Key (0: C♭ major; 1: G♭ major; 2: D♭ major; 3: A♭ major; 4: E♭ major; 5: B♭ major; 6: F major; 7: C major; 8: G major; 9: D major; 10: A major; 11: E major; 12: B major; 13: F♯ major; 14: C♯ major; 20: A♭ minor; 21: E♭ minor; 22: B♭ minor; 23: F minor; 24: C minor; 25: G minor; 26: D minor; 27: A minor; 28: E minor; 29: B minor; 30: F♯ minor; 31: C♯ minor; 32: G♯ minor; 33: D♯ minor; 34: A♯ minor) | |
| Key signature |
Worked example
| Key | C major |
|---|
| Sharps or flats, in the order written | None |
|---|---|
| Relative key (same signature) | A minor |
Key signature No sharps or flats
Each step uses the unrounded value of the step before it; figures on this page are rounded for display.
Frequently asked questions
How many flats are in E♭ major?
Three: B♭, E♭ and A♭. Its relative minor is C minor.
What is the key signature of E minor?
One sharp, F♯, the same as G major.