Online Metronome

A precise browser metronome: set the tempo with a slider, a number or by tapping, choose a time signature, and get sample-accurate clicks with an accented downbeat.

metronome · runs locally
tap 4+ times on the beat to set the tempo

Why timing is hard in a browser — and how this metronome solves it

The naive way to build a metronome in JavaScript is setInterval firing a sound every beat. It sounds fine for a few seconds and then falls apart, because JS timers are not guaranteed to fire on time — they queue behind rendering, garbage collection and background-tab throttling, and every late tick becomes an audible stumble.

This metronome uses the Web Audio lookahead scheduler pattern instead. A modest 25 ms timer does no audio work itself; it only looks ahead and books every click due in the next 100 ms directly on the audio hardware clock. That clock counts samples, not milliseconds of event loop, so even if the JS timer arrives late, the clicks it already scheduled land exactly on the grid. The result is timing steady enough to record against.

Using tap tempo and accents

Tap the TAP TEMPO button along with any song and the metronome averages the intervals of your recent taps to estimate the BPM — pause for two seconds and it starts a fresh measurement. Choose a time signature to set how many clicks form a bar, and leave the accent on to hear beat one pitched higher, which makes it much easier to stay oriented in 3/4 or 6/8.

Practice ideas

Work passages up in small steps: find a tempo where every note is clean, then add 4–8 BPM per pass. Recording yourself against the click is the fastest way to hear where you rush — capture a take with the Voice Recorder, or check your tuning first with the Tone Generator’s 440 Hz preset.

Frequently asked questions

Does this metronome record or send anything anywhere?

No. The clicks are synthesized on your device by the Web Audio API — no microphone is used, no audio files are loaded, and nothing you do on this page is recorded or sent to any server.

How accurate can a browser metronome be?

Very accurate, if built correctly. This one schedules every click ahead of time on the AudioContext's hardware clock, which is sample-accurate, instead of firing sounds from JavaScript timers, which can drift by tens of milliseconds. The clicks land where the audio clock says, not where the JS event loop happens to be.

What BPM should I practice at?

Slower than you think. Drop the tempo until you can play the passage cleanly and relaxed — often 50–70% of the target — then raise it a few BPM at a time, only after several perfect repetitions. Tap tempo is handy for finding the BPM of a recording you are learning.

What does the accented first beat mean?

The higher-pitched click marks beat one, the downbeat of each bar. Hearing the bar line keeps you oriented in the time signature — in 3/4 you hear HIGH-low-low, in 4/4 HIGH-low-low-low. Turn the accent off for an undifferentiated pulse.