Chord Interval Calculator
Calculates the interval in semitones between any two notes using their MIDI note numbers. Use it to identify chord qualities, transpose intervals, or analyze harmonic relationships.
About this calculator
A musical interval is the distance in pitch between two notes, measured in semitones. In the 12-tone equal temperament system, all intervals repeat within an octave of 12 semitones. The formula is: interval = (targetNote − rootNote + 12) % 12. Adding 12 before the modulo operation ensures the result is always positive regardless of note order. The result maps directly to standard interval names: 0 = unison, 1 = minor 2nd, 3 = minor 3rd, 4 = major 3rd, 5 = perfect 4th, 7 = perfect 5th, and so on. Musicians use interval arithmetic to build chords, analyze melodies, and transpose music. MIDI note numbers make this calculation straightforward because they are consecutive integers separated by exactly one semitone.
How to use
Suppose you want the interval from C4 (MIDI 60) to E4 (MIDI 64). Enter 60 as the Root Note and 64 as the Target Note. The calculator computes: interval = (64 − 60 + 12) % 12 = (4 + 12) % 12 = 16 % 12 = 4 semitones. An interval of 4 semitones is a major third — exactly the distance from C to E that defines a major chord. Try root 60, target 67 to get 7 semitones, a perfect fifth, the basis of power chords and open harmonies.
Frequently asked questions
How do I use semitone intervals to identify chord types?
A major triad uses intervals of 4 and 7 semitones above the root (major third + perfect fifth). A minor triad uses 3 and 7 semitones. A diminished triad uses 3 and 6, while an augmented triad uses 4 and 8. By calculating the interval from the root to each note in a chord, you can identify its quality without reading sheet music. This approach works for any key because interval patterns are the same regardless of which root note you start from.
Why does the chord interval formula use modulo 12?
The modulo 12 operation (%) collapses all intervals into a single octave range of 0–11 semitones. Notes that are an octave or more apart share the same pitch class — for example, C4 and C5 are both 'C' regardless of register. By reducing intervals mod 12, the calculator tells you the harmonic quality of the interval rather than its absolute pitch distance. Adding 12 before the modulo ensures the result is never negative when the target note is lower than the root.
What is the difference between a harmonic interval and a melodic interval in music theory?
A harmonic interval occurs when two notes are played simultaneously, as in a chord, while a melodic interval describes the distance between two consecutive notes in a melody. Both are measured in semitones or named intervals (thirds, fifths, etc.), and the same formula applies to both. Harmonic intervals determine chord quality and consonance, while melodic intervals shape the character and mood of a tune. Understanding both types helps composers write music that is both harmonically rich and melodically interesting.