🌸

Pink Noise Generator

Free, browser-only pink noise generator using Paul Kellet's IIR filter cascade for accurate −3 dB / octave power roll-off. Live log-frequency spectrum (where genuine pink noise looks flat), A/B/C color comparison between white / pink / brown, sleep timer (15 / 30 / 60 min), and WAV download. Useful for speaker calibration, room-mode measurement, audio testing, and sleep/focus listening.

Playback

Pink noise sounds fuller than white at the same setting. Start moderate.
Idle — press Play.

Live measurements

Current color
white / pink / brown
Sample rate
AudioContext.sampleRate
Measured slope
least-squares dB/oct — pink ≈ −3
Average level
mean dB across all bars

Sleep timer

Time remaining
—:——
Audio fades over the last 4 seconds so you aren't jolted by an abrupt cutoff.

Download WAV

Length
16-bit PCM mono pink noise (Kellet filter) at the audio context's sample rate. 60 s briefly freezes the UI (~250 ms) while filling the buffer.
Generated locally — never uploaded.
Live FFT spectrum — 48 bars, log frequency (20 Hz → Nyquist)

Pink Noise — What It Is and Where to Use It

Pink noise is a random signal whose power falls off at −3 dB per octave from low to high frequency — equivalently, its power spectral density goes as 1/f. It is the broadband noise that contains equal power in every octave, which is why a spectrum analyser configured with a log-frequency axis (like the one below) shows it as a flat horizontal band. White noise, by contrast, has equal power per Hz and slopes upward by +3 dB/octave on the same display.

Why “equal power per octave” matters

Human hearing is roughly logarithmic in frequency — one octave (a 2× jump in Hz) is the same perceptual step whether it's 100→200 Hz or 5,000→10,000 Hz. Pink noise's flat-per-octave profile lines up with that perception, so it sounds balanced rather than “hissy” (white) or “rumbly” (brown). The same property is why pink, not white, is the standard test signal for audio measurement: it excites every octave with the same power so the room/speaker response is what the analyser is measuring, not the test signal's own bias.

Common uses

  • Speaker / monitor calibration — flat-per-octave excitation paired with a real-time analyser shows the speaker's frequency response (deviations from flat) directly, without the +3 dB/oct correction needed with white noise.
  • Room-mode measurement and RT60 — pink noise excites low frequencies more than white, surfacing room modes and reverberation patterns at musically-relevant levels.
  • Sleep, focus, and infant soothing — the gentler high-frequency content (compared to white) is less fatiguing for long-session listening. Many sleep clinicians recommend pink over white for this reason.
  • Music masking — pink's spectrum sits closer to the long-term average spectrum of speech and music, so it masks intrusions more naturally than the brighter white.

How this generator works

The audio is produced by feeding uniform white noise through Paul Kellet's six-pole IIR filter, a canonical cascade of one-pole low-pass sections whose coefficients are tuned to approximate the 1/f spectrum to within ±0.05 dB from ~9 Hz to ~22 kHz. The filter runs sample-by-sample inside the browser (no external library), and the output is written into a 2-second AudioBuffer that loops via a Web Audio AudioBufferSourceNode for indefinite playback at near-zero CPU.

About the “Compare colors” button

This plays three seconds each of white, pink, and brown noise in sequence so you can hear them back-to-back. White is the brightest (most upper-frequency content); pink sits in the middle; brown is deepest and rumbliest. Each colour uses its own generator: white via direct Math.random(), pink via the Kellet IIR cascade above, and brown via a leaky integrator on white (approximates −6 dB/octave).

Frequently Asked Questions

Why does the spectrum look flat instead of sloping down?
Because this plot uses a log-frequency X axis. Pink noise has −3 dB/octave power roll-off, but each octave is the same horizontal distance on a log scale, so the constant per-octave power lands at the same height across the chart. The “Measured slope” readout fits a least-squares line through (log₂ frequency, dB) values and reports the slope in dB/octave — it should converge to about −3.0 for genuine pink. If you point an analyser with a linear-frequency axis at this output it'll show the textbook downward slope instead.
What's the practical difference between white, pink, and brown for sleep?
Roughly: white is brightest (good for masking high-frequency intrusions like keyboard clicks), pink is most balanced (closer to perceived "natural" sound; the most-recommended default), and brown is rumbliest (often preferred for ADHD focus and deep sleep). Use the Compare button to A/B/C the three at the same volume and pick what your ear prefers.
Is the 2-second loop noticeable?
Internally the audio plays a 2-second buffer of independent Kellet-filtered random samples on loop. Statistically the loop is detectable; perceptually it isn't — the spectrum is featureless and the brain has nothing to lock onto. For maximum freshness during long sessions, download a 60-second WAV and loop it in a media player whose loop point can be crossfaded.
What does the “sleep timer” actually do?
Counts down 15, 30, or 60 minutes from the moment audio actually starts playing (arming it while idle and pressing Play later resets the countdown). Audio fades smoothly over the last 4 seconds rather than cutting off abruptly. The countdown runs on the browser's wall clock so a brief tab-suspend doesn't drift it; closing the tab cancels it entirely.
Is pink noise safe for long listening?
At moderate levels (typically <50 dB SPL at the pillow) the risks are very low. The danger is sustained high-volume exposure, which can accelerate hearing fatigue regardless of noise colour. Start the slider low, increase only as needed to mask intrusions, and place the source a metre or so away rather than right next to your ear. For infants, the same conservative levels apply.
Why pink, not white, for room measurement?
A real-time analyser averaging power per octave will read pink as flat by construction. A speaker or room with a flat response will then show as flat on the display; deviations are entirely the device under test. With white noise the analyser would have to subtract +3 dB/octave to do the same job — doable but error-prone in practice.
Does this work offline?
Yes — once the page is loaded, all noise generation, the live spectrum, the sleep timer, and the WAV download work fully offline. Nothing is uploaded or fetched after page load.
What sample rate is the WAV?
Whatever AudioContext.sampleRate reports — typically 48000 Hz on desktop and many mobile devices, occasionally 44100 Hz. The exact rate appears in the “Sample rate” readout the first time you press Play.