A browser pitch detector captures audio, analyses short overlapping sections, estimates a fundamental frequency and maps accepted estimates to musical notes. A changing graph can make this process feel immediate, but capture, analysis and drawing each take time.
The browser supplies audio access and processing features; it does not automatically supply a complete musical pitch detector. The page’s algorithm, configuration and interface determine what the result means.
The signal path in six steps
| Stage | What happens | What can go wrong |
|---|---|---|
| Permission | The page requests an audio input | Permission denied or wrong device selected |
| Capture | The device provides sampled audio | Clipping, noise or input processing |
| Framing | The program selects short analysis windows | Too little evidence for the intended low note |
| Estimation | A method evaluates periodicity or related evidence | Harmonic ambiguity or an unsupported source |
| Acceptance | Weak or uncertain candidates may be rejected or smoothed | Missing notes or delayed transitions |
| Presentation | Hz becomes note, octave, cents or a curve | Wrong reference or misleading labels |
These stages can be arranged differently. Do not infer the exact implementation of every website from the fact that it runs in a browser.
See how this site measures live pitch for the current implementation and its documented reference checks.
Microphone permission and secure pages
The browser’s getUserMedia feature requests access to an input and returns a media stream after the required permission is granted. Public sites normally need HTTPS for this capability.
Browser and operating-system permissions are separate places to check. If another microphone is selected, a correct-looking meter may describe a headset, webcam or interface instead of the device you intended.
Starting an audio context may also require an interaction such as pressing a button. An inactive page is not necessarily a failed pitch algorithm; first confirm that capture and audio processing actually started.
If capture has not started after allowing access, check browser permission and audio input settings before retrying.
What the analysis window changes
A frame contains a finite period of audio. At 48,000 samples per second, 2,048 samples span about 42.67 milliseconds, while 4,096 span about 85.33 milliseconds.
A low note needs time to repeat. At 100 Hz, one period lasts 10 milliseconds; at 50 Hz it lasts 20 milliseconds. More periods can provide useful evidence, but a longer window also includes more of an onset or transition.
Window duration is not a universal end-to-end latency specification. A system can use overlapping windows, different time stamps and different update schedules. Do not automatically assign half a window as the complete delay experienced by every user.
How the fundamental is estimated
Classical methods investigate relationships such as waveform self-similarity. Autocorrelation, YIN and McLeod-style approaches differ in their calculations and candidate decisions. Neural methods use trained models and introduce different resource requirements.
The current site implementation uses classical McLeod-based DSP for its main detector, not a claimed neural singing model. Its configured fundamental search is 50–2,000 Hz.
A spectrum can help inspect components, but its strongest peak need not be the fundamental. The FFT explanation distinguishes spectral analysis from choosing a musical pitch.
Why a smoother graph can be less revealing
Rejection rules can suppress uncertain frames. Smoothing can reduce jitter, but it may also flatten vibrato or delay a genuine leap.
An unbroken line is therefore not proof of complete accuracy. A gap can honestly indicate that the estimator could not support a candidate. A confidence-like value also needs its documented definition; it is not automatically a probability that the singer is correct.
Compare the tracking guide when you need to distinguish frame estimates, continuous contours and discrete note events.
Turning hertz into a note
With A4 set to 440 Hz, a frequency can be mapped to fractional MIDI position using 69 + 12 × log2(frequency/440). A nearest-note choice and cents offset follow from the selected grid.
This mapping does not know the score. A centred F♯ can still be wrong when the intended note is F. Octave naming and calibration should remain visible when comparing tools.
The cents guide explains the ratio behind a sharp-or-flat reading.
What contributes to latency?
Capture buffering, input-device routing, analysis, scheduling, smoothing and display refresh all contribute. Wireless monitoring adds another path and may affect what the performer hears.
Do not rely on an invented universal millisecond figure or a calculation-time claim without a documented test. A fast calculation alone does not describe the complete microphone-to-screen experience on another phone.
For a practical check, observe clear isolated changes and note the device and settings. If timing is the research question, a controlled measurement needs a reference and a stated method, rather than an impression that the display feels instant.
Does browser processing mean the audio stays private?
A browser can analyse microphone samples locally. That architecture does not prove that every website avoids uploads, analytics or network requests.
This site’s current main/file analysis is implemented locally for those features. That statement concerns audio processing, not a promise that the entire site makes no requests. Read the page’s privacy information when deciding whether to provide a sensitive recording.
Do not assume offline operation either. A page must first load its required resources, and continued operation depends on its design.
A useful first session
Open the main detector, allow the intended microphone and use one clear source in a quiet setting. Stop reference speakers before singing your response.
To check a known input, start the microphone, allow browser access and try a steady reference tone on its own. In one isolated Chromium check, a generated 440 Hz PCM input gave A4 and 440.1 Hz on the Frequency Detector with A4 set to 440 Hz. Repeat your own check with your selected microphone and keep the input and the observed Hz in your notes.
Check an ordinary comfortable note before testing extremes. If the reading doubles, disappears or drifts, compare range, signal and reference instead of forcing the voice to satisfy the display.
Frequently asked questions
Does real time mean zero delay?
No. It means results are produced during the incoming stream. The amount and source of delay depend on the complete processing path.
Will a higher sample rate fix every error?
No. Frame duration, configured range, source quality and candidate selection still matter. Correct handling of the actual sample rate is essential.
Can a browser detector analyse a full band?
A monophonic method cannot independently identify every performer in a mix. Use a method designed for the actual multi-source task.
Why does changing tabs affect the display?
Browsers can change scheduling or suspend activity under some conditions. Return to the page and check its running state rather than assuming every interruption represents a musical event.
Reference basis: MDN Web Audio and getUserMedia documentation, pitch-estimation research and the inspected site implementation. Timing examples are calculations, not new device benchmarks.
