How to use the midi file inspector
- Choose a MIDI file (up to 25 MB) or drop it on the box.
- Read the header figures: format, number of tracks, timing, length, notes, tempo, time signature and key.
- Look at the tracks table for names, instruments and note ranges, and the settings table for tempo changes.
- Browse the notes in time order, then download them as CSV or copy a summary.
What a MIDI file holds
A standard MIDI file does not contain sound. It stores events: a note starts on a channel at a pitch and a velocity, the note ends, a controller changes, a program (instrument) is selected, and meta events set the tempo, time signature, key and track names. Times are stored as ticks since the previous event, and the header gives the number of ticks per quarter note. Format 0 has a single track, format 1 has several tracks played together, and format 2 holds independent sequences.
To give seconds, the inspector builds a tempo map from every tempo event in every track, then converts each tick to time with the tempo in force. A file with no tempo event is played at 120 beats per minute, as the standard says. Notes are paired by channel and pitch: a note-on followed by the next note-off with the same channel and pitch, or a note-on with velocity 0, ends a note. A note that never ends is closed at the end of its track and reported. Channel 10 is shown as percussion.
Checked against an independent reader
Three test files made with the mido library were compared with its own results. A three-track file with tempo changes from 120 to 150 and then 80 beats per minute was 3.65 seconds long, held seven notes and 28 events, and every note start and length matched to a microsecond. A one-track file at 96 ticks per quarter note was 1.00 seconds, and a file with a note left on was reported with a warning. The 128 General MIDI instrument names are used for program changes.
Use it to check a file before importing it, to see which instrument is on which track, or to get the note list for a spreadsheet. For related music tools see the online piano, the chord identifier, the note frequency converter and the metronome.
Limits and privacy
The file is read on your device and nothing is uploaded, and nothing is played. Only standard MIDI files that start with MThd are accepted; the first bytes are checked, so images, SVG and other formats are refused. Files with damaged tracks are read as far as they go and the problems are listed. The notes table shows the first 300 notes and the CSV holds all of them.
Assumptions and limits
- The file is a standard MIDI file (format 0, 1 or 2) that starts with MThd.
- Times in seconds follow the tempo events in the file, with 120 beats per minute when none is given.
- Notes are paired by track, channel and pitch in the order they occur. Overlapping notes of the same pitch are paired first in, first out.
- Channels are numbered 1 to 16, and channel 10 is treated as percussion.
Frequently asked questions
Why is the length different from my music software?
The length is the time of the last event in any track, using the tempo map from the file. Software may add padding, apply a different tempo, or count trailing silence differently. Check whether the file has tempo events in the first track.
What is the difference between format 0 and format 1?
Format 0 keeps every event in one track. Format 1 uses several tracks that play at the same time, usually one per instrument or part, with tempo and time signature in the first track. Format 2 holds separate sequences, one after another.
Can it play the file?
No. It reads and lists the contents without producing sound. To hear a MIDI file, use a player or a synthesizer; to try notes in the browser, use the online piano.
What does a note that was never turned off mean?
The file has a note-on with no matching note-off, often because the track was cut or the program made a mistake. The inspector ends that note at the end of the track so it still has a length, and lists a warning.