Pitch to Frequency Calculator
What This Tool Does
This Note ↔ Frequency Calculator lets you convert back and forth between musical note names (like A4, C♯3) and their corresponding pitch frequencies in hertz (Hz).
In Note → Frequency mode you enter a note and get its exact frequency; in Frequency → Note mode you enter any frequency and receive the nearest equal-tempered note plus the cents deviation from perfect tuning.
You can also adjust the reference tuning (A4 = 440 Hz by default) to match alternate temperaments.
How It Works (The Math)
Note → Frequency
We parse the note name into three parts:
- Letter (A–G)
- Accidental (# or b)
- Octave number (e.g. “4”)
Then we convert that to a MIDI note number:
MIDI = (octave + 1) × 12 + semitone
where “semitone” comes from a lookup (C = 0, C♯ = 1, …, B = 11).
Next, we compute the frequency using equal temperament:
f = f_ref × 2^((MIDI – 69) / 12)
Here f_ref is the reference frequency for A4 (default 440 Hz).
Frequency → Note
- Invert the above to get “semitones”:
semitones = 12 × log₂(f / f_ref) + 69
- Round “semitones” to the nearest whole number → nearest MIDI note.
- Calculate the cents offset (how far above or below equal temperament):
offset (cents) = (semitones – rounded) × 100
This tells you how many cents sharp (+) or flat (–) your input frequency is relative to standard tuning.
How to Use It
1) Toggle Mode
Check “Frequency → Note” to switch modes; uncheck for “Note → Frequency.”
2) Enter Your Value
- In Note → Frequency mode, type a note (e.g.
C#4
). - In Frequency → Note mode, type a frequency in Hz (e.g.
261.63
).
3) Adjust Reference
If you use a different tuning standard (e.g. A4 = 432 Hz), enter that value.
4) Calculate
Click Calculate (or press Enter) to see your result displayed below.
5) Reset
Click Reset (or press Esc) to clear all fields and start over.
What It’s Used For
- Instrument Tuning: Quickly verify the target frequency for any note when tuning guitars, pianos, synthesizers, etc.
- Sound Design: Map oscillator frequencies to musical notes in software synth patches.
- Music Education: Demonstrate the relationship between note names, octaves, and pitch frequencies in equal temperament.
- Audio Analysis: Identify the pitch of recorded tones and see how far they deviate (in cents) from standard tuning.
- Composition & Arrangement: Ensure precise intonation when creating microtonal or alternate-tuned pieces.