Music & audio
Frequency to musical note
Find the nearest equal-tempered note and its tuning offset.
A clear answer. Here’s how.
Continuous MIDI pitch = 69 + 12log₂(f/A4). Rounds to the nearest MIDI note 0–127 and reports the signed difference in cents, with 100 cents per semitone. Frequencies whose nearest note lies outside the MIDI range are rejected. This calculates pitch from a supplied frequency; it does not listen to a microphone.
See a worked example
Worked example
A fixed demonstration, separate from the values you enter above.
- Measured frequency (Hz)
- 442
- A4 reference frequency (Hz)
- 440
Example result
- Nearest note
- A4
- Flat equivalent
- A4
- Nearest MIDI number
- 69
- Target frequency
- 440 Hz
- Offset above / below target
- 7.85141504013 cents