How to Convert a MIDI File to MP3
- Load the file. Press Choose MIDI file to convert and pick a
.midor.midifile, or drag it onto the converter box — the whole box is a drop target, and its border turns coral while the file is over it. On a phone, the same button opens the normal picker (Files, Downloads, or Drive). The file is read straight off your device; nothing is sent anywhere. - Check what the parser found. The line under the button becomes
melody.mid · 30 notes · 0:21 of audioand stays there while the file converts. That count is the number of note-on/note-off pairs the file actually contains, so it is the fastest way to check you loaded what you meant to. If the file is damaged, the status line under the piano roll says why instead of handing you a silent MP3. - Check the piano roll. Every note the parser found is drawn at its pitch and start time. Press ▶ to hear the arrangement and drag the slider to jump anywhere; the readout shows the position and the full length, for example
0:00 / 0:21. You can seek and preview while the MP3 is still rendering — the two do not wait on each other. - Set the sample rate and bitrate. 44100 Hz writes an MPEG‑1 Layer III file; 22050 Hz writes an MPEG‑2 Layer III file. Bitrate choices follow: 128–320 kbps at 44100, 64–160 kbps at 22050, because MPEG‑2 has no legal frame above 160 kbps. Changing either setting re-converts the file that is already loaded, so set them before or after — you do not need to drop the file again.
- Download. The status line walks through
Converting…→Rendering 0:21 of audio…→Encoding MP3 at 128 kbps…→✓ MP3 ready (334 KB) — click Download MP3. The button is a plain download link named after your file:auld-lang-syne.midarrives asauld-lang-syne.mp3. On Android, long-press it if the first tap opens a player instead of saving; on iPhone it opens in the system player, where the Share sheet offers Save to Files.
How Long It Takes
Measured in Chrome on the laptop these pages were written on, default settings (44100 Hz, 128 kbps), timed from the drop to the download button:
| MIDI file | Audio length | Convert time | MP3 size |
|---|---|---|---|
| Frère Jacques — 14 notes | 8.7 s | 1.9 s | 137 KB |
| Canon in D, opening — 16 notes | 10.7 s | 2.1 s | 167 KB |
| Ode to Joy — 30 notes | 19.2 s | 2.9 s | 300 KB |
| Auld Lang Syne — 30 notes | 21.3 s | 3.4 s | 334 KB |
| We Wish You a Merry Christmas — 54 notes | 24.0 s | 3.7 s | 376 KB |
| Sparse test file — 40 notes | 9 min 50 s | 39 s | 9,219 KB |
| Dense test file — 600 notes | 38 s | 15 s | 586 KB |
| Dense test file — 4000 notes | 2 min 5 s | 4 min 17 s | 1,953 KB |
| Dense test file — 4000 notes, at 22050 Hz | 4 min 10 s | 4 min 19 s | 3,907 KB |
Size is set by the bitrate, not the sample rate: 128 kbps is 16 KB per second of audio, so the same 21-second tune comes out at 334 KB at 128 kbps and 835 KB at 320 kbps. That ten-minute file proves the point twice over — it measured 9,219 KB at 44100 Hz and 9,220 KB at 22050 Hz, but took 39 s to render at 44100 and 22 s at 22050.
The two things that cost time are the number of notes and the length of the audio, and the note count dominates. Forty notes spread over nearly ten minutes converted in 39 s, while four thousand notes packed into just over two minutes took 4 min 17 s. Halving the sample rate helps a sparse file a lot (that 39 s became 22 s) and a dense file hardly at all: the 4000-note file that ran 4 min 19 s at 22050 Hz was still rendering when I gave up on it at 6 min 40 s at 44100 Hz. Anything close to a single melody — up to 30 seconds or so, which is most of what people actually convert — is done in under four seconds at those defaults, and the piano roll and ▶ preview stay usable while a long file renders.
What the Finished MP3 Sounds Like
The synthesizer here is deliberately simple, so the MP3 is an honest transcription of the MIDI rather than a performance of it:
- One mono stream. Every channel is mixed into a single mono track — no panning, no per-track volume, no stereo image.
- A triangle wave for everything. Each note is one triangle oscillator at the note's pitch. A flute, a guitar and a string pad all come out as the same clean tone, and percussion on channel 10 is rendered at its MIDI pitch, so a snare becomes a low beep.
- Fixed loudness. Velocity is read from the file but is not applied to volume: every note ramps up over 20 ms, holds, and falls away over the last 50 ms. A pianissimo passage and a fortissimo one sound identical.
- Timing is respected. Tempo changes, time signatures, key signatures, markers, lyrics and SysEx are parsed and do not shift the notes. A note that is never released is closed one beat later, so files that omit note-offs still render.
- Very short notes are stretched. Anything under 0.05 s is rendered 0.05 s long, otherwise the envelope would produce a click rather than a pitch.
The result sounds like a clean chiptune keyboard arrangement: good for checking a melody, making a ringtone, or attaching something playable to an email. If you want the file to sound like a piano, you need a SoundFont renderer — a DAW, or fluidsynth — because sample-based instruments cannot be reconstructed from a MIDI file by any converter.
Which MIDI Files Work
- Standard MIDI Files with a
.midor.midiextension. Other extensions are refused with a message; rename the file if you know it is really MIDI. - Format type 0 (one track), type 1 (simultaneous tracks) and type 2 (sequential patterns). Multi-track files are mixed into one performance.
- Both header divisions: metrical (ticks per beat) and SMPTE timecode (frames per second × sub-ticks per frame). SMPTE files ignore tempo events entirely and are timed from the frame rate.
- Running status, SysEx dumps, cue points, text events, duplicate and short tempo events are all handled. A set-tempo value outside 20–2000 BPM is ignored and the previous tempo keeps running.
- Up to 50 MB, and up to 20 minutes of rendered audio.
Common Errors and What They Mean
Nothing fails silently — the status line names the problem in one of these words:
- Could not read this MIDI: no MThd header, so this is not a Standard MIDI File
- A renamed MP3 or WAV, a text file, or a saved-in-a-private-format file such as Cakewalk
.wrkor KarMA. Open it in the MIDI viewer first: it shows the header bytes so you can see what the file really is. - Could not read this MIDI: the file is shorter than a MIDI header
- Under 14 bytes — usually a download that stopped early.
- Could not read this MIDI: no MTrk chunks found, so the file is truncated
- The header is fine but the track data is missing, or the declared track length runs past the end of the file.
- Could not read this MIDI: contains no notes to render
- Not a single note-on with a velocity above zero anywhere in the file — an empty sequencer template, or one that carries only lyrics, markers and copyright text. Drums do count as notes, so a percussion-only file still converts; its hits just come out as the pitched beeps their MIDI key numbers imply.
- Could not read this MIDI: its note timings collapse under 0.05 s, so the tempo map is damaged
- The file parsed, but its tempo or tick resolution makes the whole piece finish in a fiftieth of a second. This used to produce a 22-byte MP3; now it stops with this message. Re-export the MIDI from its source program.
- Could not read this MIDI: has no measurable length / the header declares 0 ticks per beat
- Broken header numbers. The viewer will usually still show the note grid for these files.
- Could not read this MIDI: the browser refused access to the file
- The file was moved, deleted or is still syncing (common with a cloud placeholder in OneDrive or Dropbox). Save a local copy first.
- That file is 62 MB. The limit is 50 MB. / This MIDI runs 21 minutes. The limit is 20 minutes.
- Real ceilings, checked before any work starts. Trim the MIDI in a sequencer, or convert it in two halves.
- This browser cannot render audio offline. Try a current Chrome, Edge, Firefox or Safari.
- An old or privacy-hardened browser without
OfflineAudioContext. Any current desktop or mobile browser has it. - Could not load the MP3 encoder. Reload the page and try again.
- The encoder script did not arrive — a blocked request or an interrupted connection. Reload; the encoder is served from this site, so a content blocker aimed at "audio" scripts is the usual cause.
Try It on a Real File
No MIDI at hand? Every song page on this site publishes its own file, so you can test a conversion on a known tune: download Auld Lang Syne.melody.mid (30 notes, 21 s), drop it above, and you should get melody.mid · 30 notes · 0:21 of audio under the button and a 334 KB MP3 at the default settings. The song page shows the same melody in the player with the note list.
If you want to look before you convert, the MIDI viewer lists every track, instrument and note count without rendering audio. Going the other way, MP3 to MIDI detects pitched notes in an audio recording, and the online MIDI player plays a MIDI file with a piano roll, tempo control and A/B loop but no download.
Frequently asked questions
Is my MIDI file uploaded to a server?
No. The file is read in the browser with the File API, parsed there, synthesized with Web Audio and encoded to MP3 in the same tab. No request ever carries your file's contents, which is why the tool works with the network unplugged after the page has loaded.
What audio quality does the MP3 output have?
Mono MPEG Layer III at the sample rate you choose: 44100 Hz with bitrates from 128 to 320 kbps, or 22050 Hz with bitrates from 64 to 160 kbps. The file size is the bitrate multiplied by the audio length — 128 kbps works out at about 16 KB per second, so a 21-second tune is 334 KB. The tone itself is a triangle wave with a 20 ms attack and a 50 ms release at a fixed level, so it is a clean synthetic keyboard rather than a sampled instrument.
What MIDI file formats are supported?
Standard MIDI Files of type 0, 1 and 2, with either metrical or SMPTE time division, up to 50 MB and up to 20 minutes of audio. Files must be named .mid or .midi. Anything else — renamed audio, karaoke .kar containers, proprietary sequencer documents — is refused with a message saying what was missing.
Why does the MP3 sound different from the MIDI in my sequencer?
Your sequencer plays the MIDI through a SoundFont or VST instrument; this converter plays it through one triangle oscillator. Channels are mixed to mono, velocity does not change volume, and percussion is rendered at its MIDI pitch, so drums become single tones. The pitches, timings and tempo map are the same in both.
How long does a conversion take?
A melody of twenty seconds or less converts in two to four seconds at the default settings, and a sparse file of forty notes that runs nine minutes takes about forty seconds. What costs time is the number of notes: a test file with 4000 notes in just over two minutes of audio took 4 min 17 s. Long files are fine to leave running — the status line reports progress, and you can preview the piano roll in the meantime.
Can I change the sample rate or bitrate after loading a file?
Yes. Either control re-converts the loaded file as soon as you change it, and the download button is cleared and replaced when the new MP3 is ready. The bitrate list also changes with the sample rate, because MPEG‑2 Layer III stops at 160 kbps.