Featured image of post How to extract audio from video files with FFMPEG on Windows

How to extract audio from video files with FFMPEG on Windows

Learn how to quickly extract audio only from video files using FFMPEG on Windows.

  1. Download FFMPEG for Windows

  2. Open Powershell and use ffmpeg.exe to extract the audio from a video file (mp4, mov, avi)
    You can run this command from same directory where ffmpeg.exe is present, or consider adding to PATH.
    Output audio file is named sample.mp3

1
.\ffmpeg.exe -i 'C:\Users\elastic\Downloads\2023-05-12 23-55-03.mp4' -q:a 0 -map a sample.mp3

ffmpeg-split1-min

After a while you should see job complete notice: ffmpeg-split2-min

To extract a specific time range audio from a video file use this command and define staring time and duration using -t flag, or end time with -to flag.
This command will extract audio from the time 10:25 and for a duration of 1 minute and 50 seconds.

1
ffmpeg -i 'C:\Users\elastic\Downloads\2023-05-12 23-55-03.mp4' -ss 00:10:25 -t 00:01:50.0 -q:a 0 -map a sample.mp3

or

1
ffmpeg -i 'C:\Users\elastic\Downloads\2023-05-12 23-55-03.mp4' -ss 00:10:25 -to 00:12:15.0 -q:a 0 -map a sample.mp3
Licensed under CC BY-NC-SA 4.0
Last updated on Aug 12, 2024
Built with Hugo
Theme Stack designed by Jimmy