About the Online Tone Generator
This online tone generator plays a steady test tone at any frequency straight from your browser. Type a frequency or nudge it up and down, choose a sine, square, sawtooth or triangle wave, set the volume and press Play; changes apply instantly while the tone is sounding. Next to the controls you see the nearest musical note and how many cents it is off, plus the period and wavelength of the sound.
Use it to tune an instrument by ear, test speakers, headphones and subwoofers, find room resonances, check the range of your hearing, set up audio gear, or demonstrate waveforms and pitch in a classroom. A sine wave is a pure single frequency; square, sawtooth and triangle waves add harmonics that make them sound brighter and buzzier.
Start with the volume low — high frequencies and square or sawtooth waves sound much louder than you might expect, and prolonged loud tones can damage hearing. Small laptop and phone speakers cannot reproduce very low frequencies (below roughly 100–200 Hz), so use headphones or proper speakers for bass tests.
How to use the online tone generator
- 1Turn your device volume down before you start.
- 2Enter a frequency or use the buttons to step it up and down (octave buttons halve or double it).
- 3Choose a waveform — sine for a pure tone.
- 4Press Play and raise the volume slowly; change settings while it plays.
- 5Press Stop, or set a timer so the tone stops on its own.
Formula and method
The generator creates an oscillator at the chosen frequency f with the Web Audio API. One cycle lasts 1/f seconds, and the sound wave’s length in air is the speed of sound (about 343 m/s at 20 °C) divided by f. Doubling the frequency raises the pitch one octave.
The nearest note uses twelve-tone equal temperament with A4 = 440 Hz: 69 + 12·log₂(f/440) gives a MIDI note number, its rounded value names the note and the remainder × 100 gives the offset in cents. Samples per cycle show how finely digital audio at the chosen sample rate describes one cycle; at the Nyquist limit (half the sample rate) there are only two.
- f
- Frequency in hertz
- 343 m/s
- Speed of sound in dry air at about 20 °C
- 440
- Reference pitch A4 in Hz
Worked examples
Concert A (440 Hz sine)
440 Hz is exactly A4. One cycle lasts 1/440 s = 2.27 ms, the wave is 343 ÷ 440 = 0.78 m long, and at 48 kHz each cycle is drawn with about 109 samples. Five seconds contain 2,200 cycles.
1 kHz test tone
1,000 Hz is the standard audio test tone. Its nearest note is B5 (987.77 Hz), and it is 21.3 cents sharp of it. Each cycle lasts exactly 1 ms and the wavelength is 34.3 cm.
Subwoofer check at 100 Hz
100 Hz sits between G2 and G♯2 — about 35 cents sharp of G2. The wave is 3.43 m long, which is why low bass interacts so strongly with room dimensions.
Frequently asked questions
What frequency is the note A?+
A4, the A above middle C, is 440 Hz in standard tuning. Other A’s are octaves of it: A3 = 220 Hz, A2 = 110 Hz, A5 = 880 Hz.
Why can’t I hear very low or very high tones?+
Human hearing spans roughly 20 Hz to 20 kHz when young and the top end falls with age. Small speakers also cannot move enough air to reproduce bass below about 100–200 Hz.
What is the difference between sine, square, sawtooth and triangle waves?+
A sine wave contains only the fundamental frequency. A square wave adds odd harmonics, a triangle wave adds weaker odd harmonics and a sawtooth adds every harmonic, so they sound progressively buzzier.
Can a tone generator damage my speakers or hearing?+
Yes, at high volume. Long, loud high-frequency tones can damage tweeters and hearing, and strong low tones can overdrive woofers. Start quietly and keep exposure short.
Can I use this tone generator to tune my instrument?+
Yes — play the target note’s frequency (for example 82.41 Hz for the low E string) and tune until the beating between the tone and the string disappears.