Projects › Family › Classroom noise meter

Free classroom noise meter for your board, and how to make your own

Press Start, allow the microphone, and put it on the board. The balls bounce higher as the room gets louder, and the class earns stars for staying under the line. No sign-up, and nothing is recorded. Then make your own with a free AI assistant.

Easy 45 minutes Free · no sign-up Nothing is recorded

Your browser will ask to use the microphone. The sound is measured live for loudness only. Nothing is recorded, saved or sent anywhere.

Press Start
Quiet time0:00
Best0:00
Stars
Presets
Warn after
A star every

The microphone is only used while the meter is running, to measure how loud the room is. Nothing is recorded, saved or sent anywhere. Your settings save in this browser only.

Embed this classroom noise meter on your website

Free for blogs, class pages and school sites. Copy this code and paste it where you want the classroom noise meter to appear.

Watch it come together, start to finish
What you'll build

A noise meter your class can see from the back row

You'll describe the noise meter to a free AI assistant, paste what it writes into a file, and open it in your browser. Then add a traffic light, gentle warnings, a quiet-time reward and a full-screen mode, one step at a time.

  • Bouncing balls that jump higher as the room gets louder, with a "too loud" line
  • A traffic light and a simple meter, for when you want something calmer
  • Sliders for sensitivity and the "too loud" limit, plus presets for different activities
  • A "Shh…" message and an optional soft chime when it stays too loud for a few seconds
  • A quiet-time counter that gives the class a star for every few quiet minutes
  • A full-screen mode for the board, and friendly help if the microphone is blocked

Good for: teachers and teaching assistants who want a calm, visual way to manage noise, home educators, clubs and libraries, and anyone curious about how a web page can listen to a room without recording it.

Before you start

What you need

An AI chat assistantClaude, ChatGPT or Gemini. The free version is fine.
A plain text editorNotepad (Windows) or TextEdit (Mac; choose Format then Make Plain Text first).
A web browser and a microphoneChrome or Edge are easiest. Most laptops and tablets have a mic built in; a webcam mic works too.
First time? Read How to save and open an HTML file. It takes two minutes.
Step by step

Build it in six steps

Step 1 gives you a simple version that works, and each step after it adds more. The demo at the top of this page is roughly what you'll have once you've done every step. Yours will look a bit different, because the AI writes its own version each time.

  1. Ask for the noise meter

    Copy this prompt into your AI assistant:

    Copy this prompt
    I don't know how to code. Please make me a classroom noise meter that runs in a web browser and shows on the classroom board.
    
    Requirements:
    - ONE single HTML file (HTML, CSS and JavaScript together), no external libraries, no internet needed. I will save it and double-click it.
    - A big "Start" button. When I press it, ask for the microphone with getUserMedia and measure how loud the room is with the Web Audio API (an AnalyserNode). Never record, save or send the sound anywhere, and say so in small text next to the Start button.
    - Turn the loudness into a number from 0 to 100.
    - Show about 20 colourful balls sitting at the bottom of a dark area. The louder the room, the higher they bounce. Draw them on a canvas.
    - Draw a dashed "Too loud" line across the area. When the noise goes over it, show "Too loud" in big red letters underneath; otherwise show "Nice and quiet" in green.
    - If the microphone is blocked or missing, show a friendly message saying what to do instead of a blank screen.
    - A clean design: a dark background and big, bright, easy-to-read text.
    
    Please give me the complete file in one code block, then tell me in simple steps how to save and open it.

    Copy the code, paste it into your text editor, and save it as noise-meter.html. Double-click it, press Start, allow the microphone, and clap. The balls should jump.

  2. Make it fit your room

    Every classroom and every microphone is different, so you need to be able to tune it. Smoothing stops one dropped book from setting it off.

    Copy this prompt
    That works, thank you. Please make it fit my classroom:
    - Ask for the microphone with echoCancellation, noiseSuppression and autoGainControl all turned off, so the browser doesn't change the volume behind my back.
    - Work out the loudness as the RMS of the sound wave, turned into decibels, then map that onto 0 to 100.
    - A "Sensitivity" slider from 1 to 10 that moves the decibel range up or down, for quiet rooms or a mic far from the class.
    - A "Too loud limit" slider from 10 to 100 that moves the dashed line.
    - Smooth the reading: quick to rise, slow to fall, so the balls don't flicker.
    - Three preset buttons: "Silent reading" (very low limit), "Partner talk" (middle) and "Group work" (higher).
    - Save the settings in localStorage, but never the sound.
    
    Send me the complete updated file.
    Always ask for the complete file. Replace everything in noise-meter.html, save, and refresh the tab (F5 or Cmd+R).
  3. Add a traffic light and a meter

    Bouncing balls are great for younger children. Older classes often prefer something calmer.

    Copy this prompt
    Please add two more ways to show the noise, with buttons to switch between them: "Bouncing balls", "Traffic light" and "Meter".
    - Traffic light: a tall dark box with red, amber and green lights. Green when it's well under the limit, amber when it's close (over 70% of the limit), red when it's over. The lit one should glow.
    - Meter: a wide bar that fills from left to right, coloured green, amber or red the same way, with a white line showing the limit.
    - Use the same three colours for the "Nice and quiet / Getting louder / Too loud" words.
    - Remember which one I picked in localStorage.
    
    Send me the complete updated file.
  4. Add a gentle "Shh…"

    A short burst of noise is normal. This only reacts when the room stays too loud for a few seconds, and then leaves the class alone for a moment.

    Copy this prompt
    Please add a warning for when the room stays too loud:
    - Only count it as too loud if it stays over the limit for a few seconds. Let me choose 2, 3 or 5 seconds.
    - Then show a big, friendly "Shh…" over the picture for about 3 seconds.
    - A tick box to turn the "Shh…" on or off, and another for a gentle chime: two soft notes made with the Web Audio API, no sound files. Off by default.
    - After a warning, wait at least 8 seconds before the next one, so it doesn't nag.
    - Ignore the microphone while the chime plays, so the meter doesn't hear itself.
    - Save these choices in localStorage.
    
    Send me the complete updated file.
  5. Reward the quiet

    Praise works better than warnings. This counts how long the class stays quiet and hands out stars for it.

    Copy this prompt
    Please add a quiet-time reward:
    - A "Quiet time" counter in minutes and seconds that counts up while the room is under the limit. It goes back to 0:00 when a "Shh…" warning happens (not for every short noise).
    - A "Best" time that remembers the longest quiet stretch this lesson.
    - A gold star every few minutes of quiet. Let me choose 1, 2 or 5 minutes. Make each new star pop in. Show up to 10 stars, then a number, like "× 12".
    - A small "Reset quiet time and stars" button for the next lesson.
    - Keep the counter accurate even if the screen refreshes slowly, by using the real time between frames.
    
    Send me the complete updated file.
  6. Make it work on the board and on phones

    Copy this prompt
    I want to use this on a classroom board and on a tablet or phone:
    - A "Full screen" button that hides the settings and shows just the picture, the words, the quiet time and the stars, as big as the screen allows. Use the Fullscreen API, and if the device doesn't support it, cover the whole page instead. Escape exits.
    - Make the canvas sharp on high-resolution screens using devicePixelRatio, and redraw it when the window changes size.
    - Create the AudioContext inside the Start button's click, so phones and iPads allow it.
    - A "Stop" button that turns the microphone off properly (stop every track) so the browser's mic light goes out.
    - Friendly messages that say exactly what's wrong: blocked (how to allow the mic in the address bar, and on an iPad in Settings), no microphone found, or the mic being used by another app such as Teams. Add a "Try again" button.
    - On phones, put the settings under the picture, and make sure nothing scrolls sideways.
    
    Send me the complete updated file.
ADVERTISEMENT · IN-ARTICLE
If it goes wrong

Quick fixes

The browser won't let it use the microphone

You probably pressed Block once, and the browser remembers. Click the padlock or settings icon at the left of the address bar, set Microphone to Allow, and refresh. On an iPad or iPhone, go to Settings, then Safari (or your browser), then Microphone. On Windows, also check Settings, then Privacy, then Microphone, and make sure apps can use it. School laptops are sometimes locked down, so if the setting is greyed out, ask your IT team.

It says it needs https, or nothing happens when I open the file directly

Browsers only give the microphone to "secure" pages. A file you double-click counts as secure in Chrome, Edge and Firefox, so it should work there, although Chrome may ask for permission each time you open the file. If your browser refuses (Safari can be fussy with files opened this way), the simplest fix is to open the file in Chrome or Edge. For a link that works anywhere, put the page online for free, which gives it a secure https address (see free hosting, about 10 minutes). Pages sent inside an email preview or a file-sharing viewer usually can't use the mic, so download the file first.

The balls barely move, or they're always at the top

Move the Sensitivity slider: up if the room is quiet or the mic is across the room, down if it's sitting near a noisy table. If it's still odd, tell the AI: "Please show the raw decibel reading in small text in the corner, so I can see what the microphone is hearing." Then you can pick the right range together.

It goes quiet by itself after a few seconds of talking

The browser is turning the volume down for you, which is meant for video calls. Tell the AI: "Please ask for the microphone with echoCancellation, noiseSuppression and autoGainControl set to false." Ask for the complete file.

There's no chime

Check the chime box, your volume, and the silent switch on an iPhone. Browsers block sound until you've clicked the page, so press Start first. If it's still silent, tell the AI: "Please resume the AudioContext before playing the chime."

The microphone light stays on after I've finished

Tell the AI: "When I press Stop, or close the page, please call stop() on every track of the microphone stream and close the AudioContext." The light should go out straight away.

Make it your own

Twist it into something else

Anything that listens for loudness can be turned into something new. Change the first prompt to make:

A library quiet timer

a calm page for a study room that counts quiet minutes towards a shared goal, with a soft glow instead of a "Shh"

A dinner-table volume game

the family earns a pudding point for every five minutes the table stays under the line, with a tally on the fridge tablet

"Who's loudest?" party game

each player gets three seconds to cheer, the page records the peak and shows a leaderboard with silly titles

A rehearsal level checker

for a choir or band, showing the loudest moment of each run-through and whether the quiet bits were really quiet

A sleeping baby light

an old phone in the nursery glows softly when the room gets loud, so you can glance at it from the doorway

A snore counter

leave it running overnight and it counts loud moments and shows when they happened, without recording any sound

Why build it yourself?

Your classroom, your rules, no recordings

Many noise meter apps cost money, need an account, or are covered in adverts, and it isn't always clear what happens to the sound. Yours is one small file that you can read, that works without the internet, and that never records a thing. You decide what "too loud" means for your class, what the reward looks like and how gentle the warning is. It's also a lovely way to see how a web page can use a microphone, a canvas and sound together.

Keep going

What to build next