Skip to content
FiftyCalc Free calculators for all 50 states

Music Interval Calculator

Test cases replayed : 3 of 3 match · Methodology · No outside source listed

Pick two notes with their octaves to name the interval between them.

Result

Sample figures

Interval (within the octave)—

Semitones —

  • Whole octaves spanned—
  • Frequency ratio (equal temperament)—
  • Size in cents—

Estimate for planning only, not tax, legal, financial or medical advice. This calculator uses the method explained on this page.

Music Interval Calculator

First note: choose one of the 12 options in the list. Prefilled example: C.

First note octave (middle C = C4): enter a number from -1 to 9. Prefilled example: 4.

Second note: choose one of the 12 options in the list. Prefilled example: G.

Second note octave: enter a number from -1 to 9. Prefilled example: 4.

How to use this calculator

Fill in the fields in this order; each step takes you to its field.

  1. First note: choose one of the 12 options in the list.
  2. First note octave (middle C = C4): enter a number from -1 to 9.
  3. Second note: choose one of the 12 options in the list.
  4. Second note octave: enter a number from -1 to 9.
  5. Read the result: Interval (within the octave); the panel also shows Semitones, Whole octaves spanned, Frequency ratio (equal temperament) and Size in cents.

How this calculator works

Semitones = |(12 × octave₂ + note₂) − (12 × octave₁ + note₁)|, numbering C = 0 to B = 11 in scientific pitch notation (middle C is C4).

The interval name comes from the semitone count modulo 12; larger intervals are compound (a major tenth is an octave plus a major third). Enharmonic names are not distinguished: 6 semitones is both an augmented fourth and a diminished fifth.

In 12-tone equal temperament each semitone multiplies the frequency by 2^(1/12) and measures 100 cents, so the ratio is 2^(semitones ÷ 12).

The formula

  1. St=|12×o2+n2−(12×o1+n1)|
  2. N=Stmod12
Symbols used in the formula
SymbolMeaning
n1First note
o1First note octave (middle C = C4)
n2Second note
o2Second note octave
StSemitones
NInterval (within the octave)

Worked example

First noteC
First note octave (middle C = C4)4
Second noteG
Second note octave4
Semitones7
Whole octaves spanned0
Frequency ratio (equal temperament)1.4983
Size in cents700
  1. St=|12×4+7−(12×4+0)|=7
  2. N=7mod12=7

Interval (within the octave) Perfect fifth

Each step uses the unrounded value of the step before it; figures on this page are rounded for display.

Frequently asked questions

What interval is C to G?

7 semitones, a perfect fifth, ratio 1.4983 in equal temperament (3:2 = 1.5 in just intonation).

How many semitones in an octave?

12, a frequency ratio of exactly 2.

Related calculators