MusicXML to MIDI converter
Open a MusicXML score (.musicxml, .xml or compressed .mxl) exported from MuseScore, Finale, Sibelius, Dorico or a scanning app, and download it as a Standard MIDI File. The score is read and converted on your device; nothing is uploaded.
Converter
Or drag a file onto this box, or try a sample:
Result
| Part | Channel | Instrument | Notes |
|---|
Listen to the result in the MIDI player or check every event in the MIDI file analyzer.
What the converter reads
MusicXML describes notation, and part of it describes sound. This converter follows the parts that decide what you hear, as the MusicXML tutorial’s MIDI-compatible subset describes:
- Timing.
<divisions>and each note’s<duration>become ticks at 480 per quarter note.<chord/>notes start with the previous note;<backup>and<forward>move the position for second voices. - Pitch. Step, alter and octave give the MIDI note (C4 = 60). A part’s
<transpose>element is applied, so a B♭ clarinet part written in D sounds in C, as it should. - Ties. A note with
<tie type="stop"/>extends the note it is tied from instead of sounding again. - Repeats. Forward and backward repeat barlines,
timescounts and numbered endings (1st and 2nd time bars) are played in order. D.C., D.S. and coda jumps are not followed; the converter tells you when a score has them. - Tempo and dynamics.
<sound tempo>becomes Set Tempo events. Dynamics marks (pp to ff) anddynamicsattributes set note velocities. - Instruments. Each part becomes a track named after the part, with its
<midi-channel>,<midi-program>, volume and pan. Percussion parts use their<midi-unpitched>drum numbers on channel 10. - Compressed files. A
.mxlfile is a ZIP archive; the converter opensMETA-INF/container.xmlto find the score inside.
Grace notes are left out because they have no written duration, and ornaments such as trills are not expanded. Partwise files are supported, which is what every current notation program exports; a timewise file has to be re-exported first.
Program and channel numbers
MusicXML counts MIDI programs and drum notes from 1, as instrument lists do, while the MIDI file stores them from 0. <midi-program>1</midi-program> becomes program 0, Acoustic Grand Piano. Parts without a channel get the next free one, skipping channel 10 unless the part is percussion. The same off-by-one appears in MIDI channel numbers; see why channel numbers look off by one.
Sample scores
Each sample above is a small hand-written score that tests one feature, from a single whole note to repeats with endings, a transposing clarinet and an unpitched drum part. They are explained, with download links, in MusicXML basics. To go from MIDI to a score instead, use the MIDI to MusicXML converter. The conversion code is a tested module, musicxml-to-midi-core.mjs.