A labs.llc instrument · every sound generated, none recorded

White, pink and brown noise,
shaped on ten sliders.

A noise machine that runs in the browser. Press Play and it makes white noise, pink noise or brown noise; ten sliders, one to an octave from 32 Hz to 16 kHz, shape it; and seventeen more sounds can be laid over it, each on a slider of its own: four kinds of rain, thunder that comes when it comes, wind, surf, a stream, a waterfall, crickets, frogs, an owl, a campfire, leaves, birds, a fan and an aircraft cabin. A sleep timer fades the whole mix out after 15, 30, 60 or 90 minutes. Every slider and layer is free to use, the sleep timer included.

Every sound here is synthesised as you hear it. There is no recording behind any of them and no audio file to download: the page draws random numbers, shapes them by rule and sends the result to your speakers. On a current browser nothing loops: the noise is new every second, and no two claps of thunder are the same. The method section says exactly how each sound is made, how the thunder is held back, and what a browser that cannot do all of that gets instead.

People put steady noise on for sleep, for focus, and for masking the sounds of a room, a street or an open office. This page makes the noise and claims nothing for it: what helps is for your own ears to say.

The desk

One button, ten sliders

Nothing sounds until you press Play: a browser does not let a page start audio by itself, and this one does not try. Stop fades out instead of cutting off, and every slider glides to its new place, so nothing clicks.

The desk

Stopped. Nothing sounds until you press Play.

The mix as it sounds now, low notes on the left and high on the right. White noise draws level; pink falls 3 dB with each octave, brown 6.

Presets — a colour and a curve

Ten bands — an octave each, 12 dB up or down

Sleep timer

No timer: it plays until you stop it.

Animate

Each band wanders up to 3 dB either side of its slider, slowly, at a pace of its own.

The layers

Eighteen sliders that add up

The noise is one layer and each of the seventeen scenes is another. Bring up as many as you like: they are added together ahead of the ten bands, so the bands shape the whole mix, the rain included. The scenes are shelved under five headings; a heading says what is sounding under it whether it is open or shut.

The layers

Places to start — whole mixes made of scenes

A starting point sets every layer, puts the ten bands flat and turns Animate off. Change anything afterwards; your volume and timer are left alone.

The colour of the noise

Weatherrain, light rain, heavy rain, a roof, thunder, wind

How often the thunder comes

About one a minute, at random.

Watersurf, a stream, a waterfall
Nightcrickets, frogs, an owl
Fire and woodsa campfire, leaves, birds
Machinesa fan, an aircraft cabin

This mix: brown noise

The mix is kept in two places: after the # in this page’s address, so a copied link carries it, and in this browser, so it is here next time. The volume and the timer are yours and are never put in a link. A link sets the sliders and waits; it cannot start the sound.

The method

Random numbers, filtered

The three colours

Noise is named after light. White light holds every colour in equal measure, and white noise holds equal power in every hertz: the stretch from 100 to 200 Hz carries as much as the stretch from 10,000 to 10,100. Ears do not count in hertz, though. They hear in octaves, and each octave is twice as wide as the one below it, so white noise puts twice the power into every octave going up. That is the hiss.

Pink noise takes exactly that away. Its power falls 3 dB with each octave, which leaves the same power in every octave, and it sounds even from bottom to top. Brown noise — also called red noise, and named for Brownian motion, not for the colour — falls 6 dB with each octave and is mostly rumble.

The three colours of noise, their slope, and how this page makes each
ColourSlopeHow it is made here
White0 dB per octaveA stream of evenly spread random numbers: an xorshift generator with a period of 2128−1, seeded from the browser’s cryptographic one.
Pink−3 dB per octaveThat stream through Paul Kellett’s pink filter — six simple one-pole filters, a delayed tap and the raw stream, added together — which by his figures holds the slope within 0.05 dB from about 10 Hz up.
Brown−6 dB per octaveThat stream integrated — a running sum that leaks, with its corner at 16 Hz — and then high-passed at the same 16 Hz, so nothing is spent below hearing.

Measured, not assumed: a twelve-second render of each colour, fitted across the octaves from 63 Hz to 8 kHz, comes out at 0.0, −3.0 and −6.0 dB per octave at a 48 kHz sample rate. The random numbers are new every time you press Play, so a measurement of your own will differ by a few hundredths.

The ten sliders

Ten peaking filters in a row, centred an octave apart from 31 Hz to 16 kHz (the labels are the customary 32 and 63), each an octave wide and each good for 12 dB up or down. With all ten at zero they do nothing at all, and what you hear is the colour as it was generated. Neighbours overlap, so two sliders raised together lift the notes between them by more than either does alone.

A preset is a colour and a curve. White, Pink and Brown are the three colours with the sliders flat. Deep is brown noise with the top taken off; Bright is white noise with the bottom taken off. Speech blocker is pink noise leaning on 250 Hz to 4 kHz — roughly the band a telephone carries, where the parts of a voice that make words intelligible sit. The name is the usual one and it overstates: it covers speech, and no noise blocks it. Shuffle picks a colour and a curve with the browser’s cryptographic random numbers.

How each scene is made

The seventeen scenes are impressions built by rule. None of them was recorded anywhere, and their settings were arrived at from how each sound is physically made and by measuring what the rules produce, not copied from a recording. Nobody tuned them by ear: what the measurements cannot say is whether each one convinces, and that is yours to judge.

The first six are built from the same three noises, with filters and slow movement:

Rain
Pink noise kept to the band from 450 Hz to 7.5 kHz, with a lift around 2.6 kHz, is the sheet of rain. About 220 random impulses a second in each ear, ringing two band-pass filters at 2.8 and 5.6 kHz, are the drops. Brown noise under 220 Hz is the wash beneath, and the sheet swells and eases by a decibel or so over a quarter of a minute.
Wind
Pink noise through a band-pass filter that a slow random signal carries between about 310 and 870 Hz, louder as it rises: the gusts. A second, much narrower filter near 1.3 kHz is the whistle, and it only speaks at the top of a gust. Brown noise under 160 Hz is the bed.
Surf
Two trains of waves, one every 9.7 seconds and one every 14.3, so the pattern takes about twenty-three minutes to come round. Each wave is pink and brown noise through a low-pass filter that opens from 380 Hz to about 2.5 kHz as the swell rises and closes as it drains, with white noise above 3.2 kHz for the foam at the crest.
Stream
White noise in a broad band around 1.8 kHz is the run of the water. Four narrow band-pass filters between 500 Hz and 2.3 kHz, their pitch shaken a few times a second by random signals, are the gurgle.
Fan
Pink noise under 1.4 kHz is the moving air, fluttering by under a decibel 12.5 times a second. The motor is three very narrow bands of noise at 118, 236 and 354 Hz: narrow enough to sound as a hum, and never perfectly steady, as a real one is not.
Cabin
An airliner in the cruise: brown noise under 210 Hz, a broad resonance near 150 Hz, a band of rush around 600 Hz, a quiet hiss between 1.6 and 5.2 kHz for the air vents, and two narrow drones at 86 and 172 Hz, the whole drifting by about a decibel over half a minute.

The eleven scenes made of events

A drop on a roof, a clap of thunder, a pop in a fire, a cricket’s chirp: these are events, and a sound made of events cannot be had by filtering a steady noise. So each of the other eleven scenes is a small program of its own, running on the browser’s audio thread and computing its sound sample by sample. When each event comes, how big it is and what pitch it rings at are drawn from random numbers as the sound goes, so none of them holds a loop and none repeats.

Light rain
Small drops, far apart: about 26 a second in each ear, each one a tick that rings somewhere between 2.4 and 6.6 kHz and dies away in a few thousandths of a second. Behind them the rest of the rain is a thin hiss between about 1.6 and 6.5 kHz. There is no low wash at all.
Heavy rain
Big drops, and so many that they run together: about 1,300 a second in each ear, ringing two filters at 950 Hz and 2.3 kHz, over pink noise that leans on 1.1 kHz — lower than Rain’s 2.6, because a big drop hits harder and lower. Ten or so a second land close enough to be heard singly, as splats between 320 and 940 Hz. Brown noise between 70 and 300 Hz is the water already down, and the whole comes in bands, swelling and easing by about two decibels on three slow cycles of 14, 23 and 38 seconds.
Rain on a roof
A sheet-metal roof, heard from underneath. About 70 drops a second in each ear, and a drop here does not hiss, it drums: it strikes a panel that rings in five notes of its own between 310 Hz and 2.4 kHz, not in tune with one another, the lowest ringing longest (about a thirtieth of a second). Each drop strikes the five unevenly, as one does that lands in a different place. A small tick near 3.6 kHz is the strike itself, and pink noise between 130 and 520 Hz is the rain outside, heard through the roof.
Thunder
Lightning heats a channel of air several kilometres long all at once. Its sound arrives nearest part first, a third of a kilometre to the second — which is why thunder rolls — and the air takes the high notes out on the way. A strike here is that by rule: five to sixteen arrivals, crowded towards its start, each adding to a loudness that rises, falls and is added to again; noise under that loudness through a low-pass filter that opens at each arrival and closes as the strike ages; and a rumble under 62 Hz that follows more slowly and lingers. Three strikes in ten are near: a clap, bright to between 1.5 and 3 kHz, most of it over in four to thirteen seconds. The rest are far: they swell out of nothing, the farthest never brighter than 300 Hz, and roll for seven to nineteen seconds. When the next one comes is drawn at random — on average about every 11, 25, 58 or 135 seconds, as you choose, and never under three — so knowing when the last one came says nothing about the next.
Waterfall
Falling water breaks into drops by the million and no one of them is heard: what arrives is noise, and very nearly steady. Pink noise from 120 Hz up is the body; noise under 150 Hz, heaving by a decibel or so, is the roar of the pool; hiss above 3.8 kHz, flickering a little, is the spray. The top is rolled off above 9 kHz, as air does to a sound that has come some way.
Crickets
A field cricket draws a scraper on one wing across a row of teeth on the other. Each closing of the wings is one pulse: about a sixtieth of a second of a nearly pure tone, at the pitch the wing itself rings at. Six of them here, each at a pitch of its own between 4.2 and 5.2 kHz, three or four pulses to a chirp (now and then one more), a chirp every 0.4 to 0.6 seconds, drifting in and out of step with one another and now and then falling silent for a few seconds. A seventh, a tree cricket near 3.1 kHz, does not chirp but trills, for two to nine seconds at a time. Behind them a narrow band of noise at the same pitch is the rest of the field.
Frogs
Five spring peepers: each call is one clear whistle near 3 kHz that slides up about a tenth of its pitch in an eighth of a second, about once a second, each frog at its own pitch and pace. Under them, two frogs that croak: a hundred-odd puffs of air a second, each ringing at about 480 Hz and 1.15 kHz, for a third of a second at a time, in ones, twos and threes, with four to twelve seconds between.
Owl
A hoot is one of the simplest sounds a bird makes. This is the call of a great horned owl by its rhythm — a long hoot, a short one, then two or three long — near 345 Hz: nearly a pure tone, with a trace of its second and third harmonics, each note sagging a little in pitch as it goes. It calls every 13 to 37 seconds, and about one call in three is answered a few seconds later from farther off, a minor third higher.
Campfire
Three sounds. The crackle: wood holds water and resin in closed cells that burst when they are heated, so each pop is a sharp click with a short ring somewhere between 0.4 and 6.3 kHz — many small ones and a few big, a big one lower and longer — and they come in flurries, as when a log shifts. The flames: noise under 170 Hz that flutters several times a second, with a lapping near 390 Hz. And now and then, for a second or so, a hiss above 4.5 kHz: sap boiling out of an end.
Leaves
A leaf in a breeze taps its neighbours, each tap a tiny dry tick, and a tree has a hundred thousand leaves, so what is heard is a grainy hiss. Here it is noise from 1.5 kHz up whose grain is shaken about fifty times a second, under a slow random signal that is the gusts. A gust makes it louder and brighter together — its filter opens from 2 to 5.8 kHz — and at the top of a strong one there is a soft rush between 150 and 420 Hz for the boughs. Nothing about the gusts repeats.
Birds
Not a dawn chorus, which is beyond a page of arithmetic, and not any species: six birds making five kinds of call that are simple enough to build by rule from whistles that glide. A two-note call near 3.9 kHz, the second note lower; a see-saw between about 4.5 and 3.6 kHz, three to five times over; a falling trill of eight to fourteen quick notes from about 6.4 kHz; a warble of four to seven notes between 2.2 and 4.2 kHz, different every time, from two birds; and the low five-note coo of a dove near 450 Hz. Each waits some seconds between calls, by chance.

The owl, the frogs and the birds stand in a little room made of four delay lines, so that a call made of pure tones has the air of a wood or a pond around it. The room is kept faint: one that rings strongly turns a slow, pure note such as a hoot into two. That is arithmetic too; no room was sampled.

There is no café and no crowd. A room full of voices cannot be made convincingly out of filtered noise, and this page will not pass a recording off as something else, so it is left out. A second, slower surf is left out as well: it would have been the surf already here with other numbers, not another sound.

How the thunder is held back

Thunder is the one layer that is silent for a minute and then is not, so it is held three ways. First, every one of the eleven newer scenes has a ceiling: with its slider at 100, no sample of it passes 0.9 of full scale. The drops of plain Rain reach more than twice that at the same setting, so a clap is never the loudest thing a slider lets through; and the slider and the volume scale it down from there like everything else. Second, no clap arrives all at once: the nearest is let in over about a hundredth of a second and most over more, where real thunder close by takes a thousandth. Third, strikes that overlap do not pile up: two at once are held to the loudness of one. All of that holds a clap back; none of it makes one soft. A clap is meant to be heard over the rain, and how far over is for its slider, and your ears, to say.

Measured, not assumed: an hour of thunder at its busiest setting with the slider at 100 — 333 strikes — peaked at 0.89 of full scale, under its ceiling; its loudest twentieth of a second measured 0.38, where steady rain holds 0.22 all the time; and the biggest step from one hundredth of a second to the next was 0.30. Other random numbers give other strikes and figures within a few hundredths of these.

The timer, and Animate

The sleep timer runs on the audio clock, not the page’s. The fade is scheduled the moment the timer starts, so it happens on time even when the tab is in the background and the browser has slowed everything else in it down. The last minute is the fade; then the sound stops and the page says when it did.

Animate adds a very slow sine wave to each of the ten bands, each with a period of its own between 37 and 113 seconds, moving that band up to 3 dB either side of where its slider sits. The sliders stay where you put them; the spectrum shows the movement.

How loud it is

The page cannot know. It sets a level between nothing and full scale, and how loud that is in the room depends on your device’s volume, its amplifier and its speakers or headphones, none of which a web page can measure. So there is no loudness figure anywhere here: the decibels on the sliders are differences between bands, not sound levels. A soft limiter sits last in the chain: up to six-tenths of full scale it does nothing at all, and above that it rounds the peaks off, so that many sliders pushed up together do not clip. With all eighteen layers and all ten bands at the top the sound is squashed flat against it and is not pleasant, but it still does not clip.

For hours of listening, and above all for sleep, keep it low. About as loud as quiet talk is plenty; if you would have to raise your voice to speak over it, it is too loud. Start with your device’s volume down and bring it up.

On a phone

Where the browser allows it, the sound carries on with the screen locked and the lock screen offers a pause button. Some phones stop a web page’s audio when the screen locks whatever the page asks for, and an iPhone’s ring/silent switch may mute it; those are the phone’s decisions and the page cannot overrule them. If the system does pause the sound, the desk says so and waits for Play.

What the page loads, sends and keeps

The sound is made by three scripts of this page’s own: assets/js/noise-core.js (the generators and the mixer), assets/js/noise-worklet.js (the same generators, run on the browser’s audio thread and loaded when you first press Play) and assets/js/noise.js (this desk). No audio file is requested, and these three scripts send nothing: the only requests they cause are for that second script and, while something is playing, for the site’s own icon, which the browser shows on its media controls. A browser without an audio worklet, or one in which that second script fails to load, gets the same generators run once into buffers of 524,288 samples — 10.9 seconds at a 48 kHz sample rate, 11.9 at 44.1 kHz — and looped. The eleven scenes made of events are not looped even then: the same programs run in the page itself, about three seconds ahead of the moment you hear them, so thunder there is as new each time as anywhere. The desk says so, and which of the two it was, beside the Play button when that is the case; after a failed load, reloading the page puts it right.

The desk keeps one entry in this browser, labs.noise.v1: your mix, your volume and your timer choice. The mix is also written after the # in the address, a part a browser never sends to a server with the page request. The site’s shared furniture — the menu’s search, the assistant, the analytics every labs.llc page carries — loads as it does everywhere else, and that is the one way a setting can leave this browser: the analytics, on labs.llc only, may record the address as it stands, mix included. A set of slider positions is all that is in it; the volume and the timer never are. Questions and corrections: labs@labs.llc.

About

A noise machine, and nothing it is not

This is a generator of steady sound with a mixer in front of it. It is the kind of thing people leave running to fall asleep to, to work beside, or to take the edge off a neighbour’s television. White noise, pink noise and brown noise are the three best-known kinds, and brown noise, the deepest of them, is what the desk opens on.

It makes no promise about any of that. Whether noise helps you sleep or concentrate is a question about you, not about the noise, and this page has measured its own output and nothing else. Masking is the one effect that is plain arithmetic: a steady sound raises the floor that other sounds have to rise above, so a door or a voice stands out less. It does not cancel them, and it is not hearing protection.

It is not a library of recordings either. Everything is made by rule in the page, which is why there are seventeen scenes and not seven hundred: a scene is only here if it can be built honestly out of random numbers and rules. Elsewhere in the Sound room there is a tuner, a drum machine whose voices are synthesised the same way, and a live equaliser for the sound around you.