FFmpeg · Command Guide

How to Extract Audio From a Video With FFmpeg

Pulling just the audio track out of a video file — useful before running a transcription tool, which almost always wants audio-only input.

Pulling just the audio track out of a video file — useful before running a transcription tool, which almost always wants audio-only input.

The command

ffmpeg -i input.mp4 -vn -acodec pcm_s16le -ar 16000 -ac 1 output.wav

What each flag does

-vnDrops the video stream entirely — output is audio-only.
-acodec pcm_s16leUses uncompressed 16-bit PCM, the format most speech-to-text models expect.
-ar 16000Resamples to 16kHz — the standard sample rate for speech recognition models like Whisper.
-ac 1Downmixes to mono — speech transcription doesn't need stereo, and mono halves the file size.

Where this goes wrong

If you skip -ar 16000 and leave the source's original sample rate (often 44.1kHz or 48kHz), most transcription tools will still work — they resample internally — but you're shipping a needlessly large file for no accuracy benefit.

If you just want a smaller compressed audio file instead

ffmpeg -i input.mp4 -vn -c:a aac -b:a 128k output.m4a

Use this version when the audio is the deliverable itself (a podcast clip, a voiceover to reuse) rather than an intermediate file for transcription.

After the command

This is the exact first step NULLFRAME's templates run automatically — extracting clean audio, then transcribing it with real word-level timestamps before touching anything visual.

Get the kit

Common questions

Why WAV and not MP3 for transcription?+
Uncompressed PCM avoids any compression artifacts that could confuse a speech model, and most transcription pipelines accept WAV directly without a decode step.
Can I extract audio from multiple videos at once?+
Yes — wrap the command in a shell loop over your files, or use FFmpeg's -i multiple times with a filter_complex if you need them merged.
Does this work on any video format?+
Yes, as long as FFmpeg can decode the container and codec — which covers effectively every common video format.