How to determine the codec of an audio file on Windows?

stinepike picture stinepike · Apr 5, 2011 · Viewed 29.5k times · Source

I need to find the codec of an audio file. How can I do this?

Do I need to write code to do this or is there a simpler way?

Please help me. If possible share helpful links.

Answer

Andrea Spadaccini picture Andrea Spadaccini · Apr 5, 2011

The good old file utility will reveal lots of information about audio files, sometimes including the codec:

$ file X.wav 
X.wav: RIFF (little-endian) data, WAVE audio, Microsoft PCM, 16 bit, mono 16000 Hz