Question · Speech recognition
Which audio formats and file sizes does Whisper accept?
Yes, Whisper accepts m4a. OpenAI's transcription API takes mp3, mp4, mpeg, mpga, m4a, wav and webm files up to 25 MB each, and the open-source package reads any format that ffmpeg can decode, while each app sets its own limits.
Updated October 17, 20263 min read4 cited facts, each traced to its source
Yes. Whisper accepts m4a files. The answer depends on how you use the model, though. OpenAI's hosted transcription API lists seven formats 1, including m4a, and caps each file at 25 MB 2. The open-source model reads audio through ffmpeg, so it takes whatever ffmpeg can decode. An app built on Whisper may set its own format and size limits, and those limits can make an upload fail even when the file is fine.
OpenAI's API takes seven formats, including m4a
OpenAI's speech-to-text guide lists the supported input formats as mp3, mp4, mpeg, mpga, m4a, wav and webm 1. So if your recording is an m4a from a phone or a voice memo app, you can send it to the API as it is. The list describes what the API accepts on the day it was read. It does not say which formats a desktop or phone app accepts, so check the app separately.
The API caps each file at 25 MB
The Transcriptions API accepts files up to 25 MB, and for larger recordings the guide says to use a compressed audio format or split the file into chunks of 25 MB or less 2. Size is the limit you will hit most often. A long recording in a high-quality format can exceed 25 MB, while the same audio at a lower bitrate can fit.
The limit applies per file, and it is a request limit, not a limit on the total audio you can transcribe. If the file is larger, split it into pieces and transcribe each one. Keep the pieces at natural pauses, so no sentence is cut in half.
The open-source model reads any format ffmpeg can decode
If you run the open-source Whisper package yourself, the audio is decoded before the model sees it. Whisper's load_audio function starts the ffmpeg command-line tool as a subprocess to decode the file, and it needs ffmpeg in the PATH to do so 3. The formats you can use are therefore the formats your ffmpeg build can read, and m4a is among the common ones. The package has no 25 MB cap, because the limit belongs to the hosted API.
Some tools are stricter. The whisper.cpp command-line example runs only with 16-bit WAV files, so you must convert other formats before you run it 4. That is a property of one tool, not of the Whisper model.
Why an upload fails, and what to check first
When an upload fails, the cause is usually one of four things.
- The file is over the size limit. Check the size in megabytes. Anything above 25 MB will fail on the hosted API.
- The format is not accepted. Convert to mp3 or wav and try again. A file that plays on your phone is not always in a format the service accepts.
- The app has its own limit. Many apps set a lower maximum or a maximum length, and their documentation states it.
- The connection or key is wrong. A rejected key or a dropped connection looks like an upload error, so test with a short file before you assume the file is at fault.
What to do: convert or split the file, then test a short piece
- Check the file size and format. Note the size and whether the extension is m4a, mp3 or wav.
- Split or compress a large file. Split it into pieces of 25 MB or less, or re-encode it in a compressed format.
- Convert an unsupported format. Use ffmpeg to write an mp3 or a wav copy, then upload the copy and keep the original.
- Test with a short clip first. If a short clip works and the full file does not, the size or length is the cause.
- Read the app's limits. If you use a Whisper app, look up its maximum file size and supported formats in its documentation.
If you only need a transcript once and do not want to set anything up, a free audio-to-text tool runs in your browser. For the price of the hosted API, see the guide to OpenAI's speech-to-text pricing, and for the setup of the open-source model, read the guide to running Whisper locally. The question on whether Whisper AI has an API explains the difference between the hosted service and the open-source model.
Evidence
Every number on this page, with where it comes from. Open a fact to see the exact words in its source.
- 1.
- 2.
- 3.
- 4.