How can I convert mp3 audios to midi for web?

  • 1
    Do you mean to program it, or just to convert it? – The Communist Duck Mar 5 '11 at 13:56
  • 6
    Not feasible in general: MP3 is a waveform encoding (any sound), whereas MIDI encodes instruments playing notes (limited instrument set, limited note set). Analogy: like converting an image to ASCII art - it can be done with effort (with much better results for manual recoding), but the result will not be very similar to the source. – Piskvor left the building Mar 5 '11 at 14:04
  • @Piskvor It is feasible, but it's a large piece of audio analysis software. See Intelliscore for a commercial implementation, but I believe it still requires a skilled human operator to set the parameters for conversion. – Adrian Cox Mar 5 '11 at 14:08
  • @Adrian Cox: "it still requires a skilled human operator" - I was assuming the OP wanted to do this programatically, hence my comment. – Piskvor left the building Mar 5 '11 at 15:58

You can't. At least not in any reasonable quality, with current computing technology.

Think of it like this. An MP3 is a CD, and a MIDI file is sheet music. The conversion from the former to the latter requires, at least at this point, a human being.


Well, not directly, and the sound won't be EXACTLY the same- but it will be very close. Secondly any vocals will be converted to an instrument. cool, but not that useful. in addition this solution would need a linux based system, since the tool i recommend is a linux based tool

I'd first use ffmpeg or sox to convert the mp3 to a Wav file, then run waon to convert that to midi. load it up into a midi editor, remove the 'voice' track, and you have a fairly close midi file to the original track.


There is not a way to actually convert MP3 files to MIDI files, like Matti Virkkunen mentioned in his answer. However, is is possible to do so to some extent, although most of the information will be lost (for example the output may only "use" 1 MIDI instrument); the way this can be done is pretty much similar to the way a person can listen to a song and write down the notes (where the song will be in the notes, but without all of the instruments etc. that were in the real thing).

WIDI Recognition System may be able to do this, but I am not aware of whether it works or not.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy