MediaRecorder
Records a camera, mic or screen stream to a file in the page.
In one line
Can save a camera, mic or screen stream to a file, once you allowed it
Records a camera, mic or screen stream to a file in the page.
Turns a live stream into stored audio or video. Needs a stream the person already allowed; the point is the site can keep a copy, upload it, or hold it in memory.
What it can and can't do
What the user does: You click Record on a page that already has camera, mic or screen access
It can
- Record video or audio from a stream you already allowed
- Save the recording in the page and offer it to download
- Upload the recording to the site's servers
- Stop and start recording while the tab stays open
It cannot
- Record anything without an allowed camera, mic or screen share first
- Record sources you did not allow
- Show its own prompt; the only prompt is for the camera, mic or screen
- Keep recording once the source stops or the tab closes
Browser support
| Browser | Status | First version | Released | Note |
|---|---|---|---|---|
| Chrome | Supported | 47 | 2015-12-01 | None |
| Edge | Supported | 79 | 2020-01-15 | None |
| Firefox | Supported | 25 | 2013-10-29 | None |
| Safari | Supported | 14.1 | 2021-04-26 | None |
| Safari on iPhone | Supported | 14 | 2020-09-16 | None |
| Chrome on Android | Supported | 47 | 2015-12-02 | None |
| Samsung Internet | Supported | 5.0 | 2016-12-15 | None |
How a site asks for it
| API | new MediaRecorder(stream, {mimeType, videoBitsPerSecond}); start(timeslice); ondataavailable |
| Browser compat keys | api.MediaRecorder |
| How access is granted | none |
| What the user sees | No prompt of its own; permission comes from the source stream. |
| Needs a secure context (HTTPS) | Yes |
| Needs a user gesture | No |
| How long it lasts | Follows the stream grant |
| How to take it back | Stop the tracks or stop the recorder |
| Inside an iframe | Frames inherit stream permissions |
Typical flow
- Get a MediaStream (camera, mic, screen)
- new MediaRecorder(stream)
- start(timeslice)
- ondataavailable gives Blob chunks
Data you get
What comes back: Encoded audio or video chunks
Shape: binary
How often: every timeslice ms (default 0, one blob at stop)
| Field | Type | Unit | Range | Precision |
|---|---|---|---|---|
mimeType | string | MIME | video/webm, audio/webm, video/mp4, audio/ogg | browser dependent |
videoBitsPerSecond | integer | bits per second | 100 kbps to about 25 Mbps | 1 |
Technical limits
- Cannot record without a stream
- Limited to memory and quota
- Container format differs per browser
The story
What it is
Lets a page record a live camera, mic or screen stream and keep it as a file.
For you
You do not see a prompt for this itself. It only works on a stream you already allowed, such as your camera. If the site records, you may see a red dot or a Recording note, but it is not required.
For makers
Recording turns a live moment into a product: a saved message, a replay, an upload for later review. It also lets a maker keep a copy of calls for training and compliance. Because it runs in the browser, there is no extra app to build or ship.
Where you see it
| Type | Example | Apps |
|---|---|---|
| video | In Loom or a similar tool, you press Record, speak and share your tab, and the page saves it as a video file you can send. | Loom, Screencastify |
| messaging | A voice note button in a web chat records your voice from the mic and sends it as a short audio clip. | WhatsApp Web, Telegram Web |
| games | A browser game lets you press a key to record your last 30 seconds of play, and the page makes a clip to share. | None named |
| education | A language app records you saying a phrase, then plays it back next to the native speaker so you can compare. | Duolingo, Babbel |
| enterprise | A sales call site records the call in the browser and uploads it for coaching, when the host turns recording on. | Gong, Zoom web |
| security | A video ID check records a short selfie clip and sends it to a server to confirm you are a live person. | Persona, Onfido |
| creative | A podcast tool records your mic locally at high quality, then uploads the file after the show, so a bad connection does not ruin it. | Riverside, Descript |
Risks
- Copy of a call kept without everyone's knowledge
- Recordings stored on a vendor server
What the platform says
- Mozilla: MediaRecorder. Developer docs show how a page can record audio or video streams into chunks and save or upload them.
Good uses and abuse
Legitimate uses
- Voice notes
- Screen recordings
Known abuse
- Persistent hidden recording after consent
Scores
| Score | Value | Meaning |
|---|---|---|
| Sensitivity | 3 of 5 | How revealing the data is |
| Utility | 4 of 5 | How useful it is to honest apps |
| Friction | 0 of 5 | How much the user has to do |
| Fingerprint bits | Not rated | Rough identifying entropy, when known |
History
- 2021-01, Safari 14.1: MediaRecorder ships in Safari
- 2025-09, Safari 26: ALAC and PCM recording formats
Related capabilities
Related
- Camera (video capture). Can see and record live video from your camera while the tab is open
- Microphone (audio capture). Can hear and record live audio from your microphone while the tab is open
Sources
How well checked: Based on official documentation.