Sheet Music to MIDI: Why a PDF Becomes MusicXML First
Short answer
Sheet music to MIDI is reading, not converting.
A printed score is a picture of notation, so software has to recognise the symbols before any file can exist. That step is called optical music recognition.
This tool does not do it. The converter here reads audio and has never seen a score. If a PDF is your starting point, the file you want out of the recognition step is usually MusicXML rather than MIDI, because MIDI carries the notes and none of the notation.
Convert audio to MIDI instead Runs in your browser, no upload, no sign-up.
Sheet music to MIDI means reading a picture
A score on paper or in a PDF is an image. It shows notation to a person and stores nothing a machine can read directly.
Turning it into a file means recognising each symbol in turn: the staff, the clef at the start, where every notehead sits, and what shape it has.
That job has a name. Optical music recognition, usually shortened to OMR, is to scores what OCR is to scanned text.
Why the output is usually MusicXML, not MIDI
MIDI and MusicXML are not two names for the same result. MuseScore's handbook describes MIDI as a standard that encodes all the notes and instruments in a score, but none of the visual formatting.
The same handbook is blunt about the cost. A MIDI file does not preserve visual formatting, so it looks very different when opened in any notation program compared to the original score.
MusicXML is the format that aims to preserve as much of the original score formatting as possible. If you want an editable score at the end, ask the recognition step for MusicXML, and export MIDI afterwards if you still need it.
What the recognition has to recover
Pitch is not stored anywhere. It comes from the clef plus the position of the notehead on the staff, so the clef has to be read before any note can be named.
Duration comes from the notehead and the flags or beams on the stem. A filled head with one flag and a filled head with three are different lengths drawn from the same shape.
Accidentals are contextual. A sharp in the key signature applies for the whole bar, a sharp in front of a note applies to that note, and neither is written into the note itself.
Then there is the layer that is notation and nothing else: ties against slurs, repeats, first and second endings, ornaments, and lyrics under the staff.
What to check before you scan
Recognition works from pixels, so the picture decides the result. A straight page reads better than a photographed one, and even light beats a shadow falling across the staff.
Handwritten scores are harder for a different reason. The symbols vary from hand to hand, so there is less regular shape for the recognition to match against.
Feed it the cleanest copy you have. Cropping to the music and straightening the page takes a minute and removes two of the commonest sources of wrong notes.
What MIDI carries, and what it never carries
Whatever produces the MIDI, the file has a fixed set of slots. This converter writes SMF format 1 with one track and a division of 480 tpqn, a track name, one tempo event, and note-on and note-off pairs carrying pitch and velocity.
It writes no key signature event and no time signature event. There is no barline in the file either, because MIDI has no barlines to write.
Note spelling is not there. The file stores 61 as a number, and whether that reads as C sharp or D flat is decided later by whatever opens it.
If your source is a recording instead of a score
The other direction starts from sound. If you have a recording there is nothing to read and nothing to scan, because the pitch has to be estimated from the waveform.
That is what the converter on this site does. It decodes the audio in your browser, tracks the pitch on your own device, and writes the MIDI in memory. Nothing is uploaded and there is no sign-up.
On this build's own C major test, with the ground truth known, 8 of the 8 notes come back at the correct pitch. Timing is the harder half, and it is measured rather than played.
Sheet music, score, PDF, scan: the same input
These are four names for one starting point. Sheet music and score describe the same page, a PDF is a common container for it, and a scan is how a paper copy becomes a file.
None of them changes the job. Every one of them needs recognition before anything else can happen.
FAQ
What does sheet music to MIDI actually mean?
It means turning a picture of notation into a file of notes. The score has to be read symbol by symbol first, because a PDF or a scan stores an image and not music data. The recognised result is exported as MusicXML, and as MIDI if you need it.
Can I convert a PDF to MIDI directly?
You can, but the direct route loses the notation. A PDF is an image, so it has to be recognised before any file exists, and if MIDI is the only output you keep the notes without the key signature, the barlines, the spelling or the rests.
Is music score to MIDI the same as sheet music to MIDI?
Yes. Sheet music and score are two names for the same page, so both phrases describe one job: read the notation, then write a file. Whether the input is paper, a scan or a PDF does not change what has to happen.
What is optical music recognition?
It is the score equivalent of OCR. Optical music recognition, or OMR, finds staff lines, clefs, noteheads, stems and flags in an image and turns them into notation data. It is the step that has to happen before a scanned score can become any kind of file.
Can this site convert sheet music to MIDI?
No. The converter here reads audio, not images, so it has no way to open a PDF or a scan and it never guesses notation from a picture. What it does is the audio side: a recording in, a MIDI file out, in your browser with no upload.
Does MIDI keep the key signature and the barlines?
No. MuseScore's handbook says MIDI encodes all the notes and instruments in a score but none of the visual formatting, and that the file looks very different when opened in a notation program compared to the original score. The key signature and the barlines are part of what does not survive.
Why does a scanned score come back with wrong rhythms?
Because duration has to be read from the shape of each note and the flags or beams on its stem, and that reading depends on the picture being clear. A stem that runs into a beam, or a notehead that fills in during photocopying, changes what the recognition sees.
What should I check before scanning a score?
Start with the page itself. A straight, evenly lit copy reads better than a photograph, and cropping to the music removes margins the recognition would otherwise have to work around. If you have both a printed copy and a PDF, scan the printed one.
How do I convert sheet music to MIDI for free?
Look at what format comes back. Recognition is the expensive half, and the output decides whether you keep the notation at all. MusicXML keeps it and MIDI does not, so a free tool that returns MusicXML leaves you with something you can still edit.
The converter on this site reads sound, not scores. It turns audio into a standard MIDI file, SMF format 1 at 480 tpqn, in your browser with no upload and no sign-up. If you have a PDF or a scan, start with recognition and keep the MusicXML.