HTML muted Attribute

Beginner
5 min read
Updated: Oct 2026
3 examples
Live preview

Definition and Usage

The muted attribute is a Boolean attribute on <video> and <audio>. When present, the media starts with audio silenced. Its default (when omitted) is unmuted — sound can play if the resource has an audio track.

Pair it with controls so users can unmute, and with autoplay when a clip must start without a click — browsers usually allow muted autoplay and block audible autoplay.

Baseline · Widely available.

Not deprecated and not experimental. Stable across modern browsers since about July 2015.

Boolean — presence mutes.

muted="false" does not unmute. Remove the attribute, or set element.muted = false in JavaScript.

HTML Syntax

syntax.html
<video|audio muted> …</video|audio>

Write muted alone. Any presence means the default mute setting is on.

Attribute Values

Boolean attribute — no value list. Common patterns:

PatternDescriptionTry it
muted presentMedia starts silent; user or script can unmute laterTry it
OmittedDefault unmuted — audio may play (subject to autoplay policy)Try it
autoplay mutedTypical pattern for clips that should start without a clickTry it
muted on <audio>Same Boolean rule for audio-only elementsTry it

Live Preview

Toggle muted on a video, then press play. With mute on, you should hear no sound.

Uses the live muted property. Controls stay available so you can also unmute from the player UI.

Video

muted is present — playback starts silent

HTML Examples

Short, copy-ready snippets. Use Try It Yourself for a live editor.

Example 1 — Video Starts Muted

Silence the soundtrack until the user unmutes with controls.

HTML
<video width="400" height="225" controls muted playsinline>
  <source src="/video/count.mp4" type="video/mp4">
  Your browser does not support the video element.
</video>
Try It Yourself

How It Works

  1. Add muted so the default audio setting is silent.
  2. Keep controls so users can unmute and seek.
  3. playsinline helps keep playback in-page on many phones.
  4. User control. Never force sound without an obvious unmute path.

Example 2 — Muted Autoplay Video

MDN-style pattern for clips that should start without a click.

HTML
<video width="400" height="225" controls autoplay muted playsinline>
  <source src="/video/count.mp4" type="video/mp4">
  Your browser does not support the video element.
</video>
Try It Yourself

How It Works

  1. autoplay requests playback as soon as enough data is ready.
  2. muted makes the clip inaudible so most browsers allow autoplay.
  3. controls lets users pause or turn sound on.
  4. Policy tip. Audible autoplay without a prior gesture is often blocked — see autoplay.

Example 3 — Audio Starts Muted

Same Boolean rule on <audio> — start silent, unmute from controls.

HTML
<audio controls muted>
  <source src="/audio/count.mp3" type="audio/mpeg">
  <source src="/audio/count.ogg" type="audio/ogg">
  Your browser does not support the audio element.
</audio>
Try It Yourself

How It Works

  1. muted on audio silences output until changed.
  2. Multiple <source> improves format support across browsers.
  3. Always include controls for mute/volume and play/pause.
  4. Avoid surprise sound — muted start plus user unmute is friendlier.

Edge Cases & Pitfalls

Most issues come from Boolean misuse or expecting unmuted autoplay to work everywhere.

boolean

Do not use muted="false"

Presence means muted. Remove the attribute, or toggle element.muted in script.

autoplay

Audible autoplay is often blocked

If you need autoplay, mute the media (or use a file with no audio track) and keep controls.

api

defaultMuted vs muted

The HTML attribute maps to defaultMuted. Change the live mute state with the muted property during playback.

a11y

Provide an unmute path

Silent video can hide spoken content. Offer captions/transcripts and visible controls to restore sound.

ux

Do not surprise users with sound

Unexpected audio is disruptive. Prefer muted start (or play after a click) for background media.

Browser Support

muted is an HTML attribute for video and audio in the browser. It is not a Node.js, Deno, or Bun API.

✓ Baseline · Widely available

muted

Widely available since about July 2015. Chrome, Firefox, Safari, Edge, and Opera support muted on video and audio.

97% Global support (approx.)
Google Chrome 4+
Full support
Mozilla Firefox 11+
Full support
Apple Safari 5+
Full support
Microsoft Edge 12+
Full support
Opera 15+
Full support
Samsung Internet 4+
Full support
Internet Explorer 9+
Supported
muted Widely supported

Bottom line: Safe to use for silent-by-default media. Rely on muted autoplay when you need playback without a user gesture.

Key Takeaways

  • Role: start <video> / <audio> with sound off.
  • Boolean: present = muted; omit (or script) to unmute.
  • With autoplay: muted clips are far more likely to start automatically.
  • UX: always offer controls (or a button) to restore sound.

One line: muted starts media silent — remove it or flip element.muted when the user wants sound.

Frequently Asked Questions

It is a Boolean attribute on video and audio that starts the media silent. Users can still unmute with controls or script (element.muted = false).
The video and audio elements. It sets the default mute state for that media element.
Browsers often block autoplay when sound would play. muted (or no audio track) makes the media inaudible so autoplay is more likely to succeed.
No. If the attribute is present at all, the media starts muted. Remove the attribute (or set element.muted = false in JavaScript) to unmute.
The muted HTML attribute is reflected by defaultMuted. The live mute state is the muted property — change that to mute/unmute during playback.
For autoplay that must start without a click, yes — mute it and provide controls so users can enable sound.

Next: name

Name form controls and other elements for submission and scripting.

name tutorial →

CODETOFUN NEWS

Stay Ahead in Tech

Get the latest IT news, programming updates, and technology trends directly on your phone.

Your daily dose of tech, straight to your feed.

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

9 people found this page helpful