By Tim King · Updated
Tone Generator
Play Any Frequency and Export as WAV
OneTask is free, with no sign-up, and built by one person.
If this tool saved you time, a coffee helps keep new ones coming.
How the Tone Generator works
This tone generator plays any frequency you type. Press Play and your browser synthesises a tone at exactly the frequency you type — sine, square, sawtooth or triangle — with the waveform drawn live on the scope and the nearest musical note read out beside it. Change the frequency while it plays and the pitch slides rather than restarting. Export the tone as a WAV file when you need it on disk.
Tone generator: how it works
A tone generator is one of the few test instruments that needs no hardware. The browser's Web Audio API has a built-in oscillator that runs on the audio thread at your sound card's sample rate, so the tone is as steady as a bench signal generator for most practical purposes. Pick a frequency between 20 Hz and 20 kHz, choose a waveform, and press play. Change either while it plays and the tone follows without a restart.
Why a pure tone is useful
Music spreads its energy across thousands of frequencies at once. A test tone puts it all in one place, which lets you isolate a single behaviour:
- Speaker and headphone checks. Step a sine through the bass range and listen for rattles, buzzes or a driver that goes quiet. Small laptop and phone speakers barely reproduce anything below 150 to 200 Hz, and a tone shows exactly where yours gives up.
- Room acoustics. Low tones excite a room's resonant modes. Walk around while 50 to 120 Hz plays and you will find spots where the bass booms and spots where it almost vanishes.
- Line-up and calibration. Broadcast and studio work uses a 1 kHz sine as the reference tone for setting levels between devices, and a steady tone is the input for checking a sound level meter or an interface's gain staging.
- Hum hunting. Mains electricity runs at 50 Hz in Europe, Australia and most of Asia and 60 Hz in North America. Playing the matching tone helps confirm that a buzz in a recording is electrical rather than acoustic.
- Tuning. A 440 Hz tone is the standard A4 reference that orchestras and tuners use.
The four waveforms
A sine has energy at one frequency only, so it is the right choice for almost every measurement. The others add harmonics, whole-number multiples of the frequency you set:
| Waveform | Harmonics | Sounds like | Use it for |
|---|---|---|---|
| Sine | none | pure, flute-like | measurement, hearing checks, tuning |
| Triangle | odd, fading fast | soft, hollow | a gentler tone that small speakers can play |
| Square | odd, fading slowly | buzzy, like an old game | amp tests, audible low notes |
| Sawtooth | all | bright, brassy | demonstrating timbre, synth patches |
On a phone speaker that cannot play a 60 Hz sine at all, a 60 Hz square wave is still audible, because its harmonics at 180, 300 and 420 Hz fall within the speaker's range. Your ear infers the missing fundamental.
Reading the result
- Frequency confirms the tone actually playing, clamped to 20 Hz to 20 kHz.
- Nearest note names the closest equal-tempered pitch and how far off it is in cents, a hundredth of a semitone. For example, 432 Hz reads as A4 −32 cents, and 261.63 Hz as C4 exactly. Most trained listeners notice about five cents on a sustained note.
- Wavelength in air is the speed of sound, 343 m/s at 20 °C, divided by the frequency. A 100 Hz tone is 343 cm long, comparable to a room, which is why bass pools in corners and is hard to locate. A 10 kHz tone is 3.4 cm long and travels more like a beam, which is why tweeter aim matters.
- Period is the time for one cycle in milliseconds. A 1 kHz tone has a 1 ms period, which makes it handy for checking the time axis of an oscilloscope or a delay plugin.
Keep the level low
The volume slider starts at 20 % and is squared on the way to the output, which tracks how loudness is perceived more closely than a straight line. A sustained pure tone is more tiring and riskier for hearing than music at the same level, because all its energy sits in one narrow band of the inner ear. Start quiet, raise it slowly, and never put a high-frequency tone on headphones at a level you have not tested on speakers first.
Exporting a WAV
The export renders the same tone offline as a mono 16-bit, 44.1 kHz WAV file, from 0.1 seconds up to five minutes long. A 20 ms fade at each end stops clicks, which also makes the file loop cleanly. Drop it into any audio editor, load it on a phone as a test signal, or put it on a USB stick for a car stereo check. Nothing is uploaded; the rendering happens in this tab.
Tips and pitfalls
- Hearing tops out early. Most adults cannot hear much above 15 to 17 kHz, and the limit drops with age. Silence at 18 kHz usually says more about ears than equipment.
- Your device changes the tone. Bluetooth codecs, "enhancement" settings and speaker protection can colour or limit a test signal. Turn them off before judging a speaker.
- Square waves are loud. At the same slider position a square wave carries more energy than a sine and sounds noticeably louder. Drop the volume before switching.
- One frequency at a time. To hear how a system responds across the whole range, use the sweep generator. For your own upper limit, try the hearing range test, and to see the harmonics of each waveform, play it into the spectrum analyzer.
FAQ
Why can't I hear a 20 Hz or 19 kHz tone?
Probably your equipment rather than your ears. Laptop speakers and cheap earbuds roll off sharply below about 100 Hz, and adult hearing generally stops well short of 20 kHz — it usually falls by around a kilohertz per decade of age. Try a higher level cautiously and better headphones.
Which waveform should I use for testing?
A sine wave, unless you have a specific reason not to. It contains one frequency and nothing else, so anything you hear beyond that pitch — buzz, rattle, distortion — is being added by the equipment rather than the signal.
Is the frequency accurate?
It is as accurate as your sound card's clock, which in practice means a few parts per million. The oscillator runs at the hardware sample rate, so the tone is far more precise than anything you could measure without lab equipment.
Can I use this to tune an instrument?
Yes, as a reference pitch. Set the frequency to the note you want — 440 Hz for A4 — and tune to the sine. The cents readout also lets you set up a non-standard reference such as 432 Hz or 415 Hz for baroque pitch.
What does the export produce?
A standard 16-bit mono WAV at 44.1 kHz of whatever length you ask for, with brief fades at both ends to avoid clicks. It opens in every audio editor and player, and is rendered entirely on your own machine.
Is a sustained tone safe to listen to?
At a low level and for a short time, yes, but treat it with more caution than music. All the energy sits in one narrow band, which is both more fatiguing and more damaging at the same apparent loudness, so keep the volume slider low and take breaks.
See also: all Audio tools, Images, Video & Screen, PDF, SVG, Simulations & Screensavers, Generative Art, Chart Makers, 3D Model Viewers, Drawing Pads, Mockups & 3D Making, Diagram Makers, 3D Science, Tracker Music.
Related tools
Metronome
Drift-free metronome with accented downbeats and WAV export.
Decibel Meter
Read live sound level in decibels from your microphone.
Stereo To Mono
Downmix stereo audio to mono and export it as WAV.
Morse Code Translator
Translate text to Morse code and back again.
Ambient Sound Mixer
Mix rain, wind, waves, fire, stream and crickets into your own soundscape.