FFMPEG - Extract audio from video file and write to MP3

Published: 2018-07-29 08:26:49 +0000
Categories: BASH,




The snippet below extracts the audio track from a video file (for example an MP4), converts it to MP3 and writes it out to a file.


ffmpeg -i "$IN" -vn -acodec "$OUT"

Usage Example

ffmpeg -i happy_birthday.mp4 -vn -acodec happy_birthday.mp3



ffmpeg, mp3, audio, extract,

Latest Posts

Remotely backing up PFsense Configuration (BASH)
FFMPEG: Converting RMVB to X264 MP4 (BASH)
Recursively print table (print_r equivalent) (LUA)
Bulk Delete Comments from (Self-Hosted) JIRA Issues (Misc)
Add a static entry to the ARP table (BASH)
SSL Cipher Hex codes to Human Readable Names (Misc)
Convert Ascii to Binary (BASH)
Intercepting Outbound DNS Queries (BASH)
Handle Google Verification files within NGinx Configuration (NGinx)
Getting WhatsApp Rich Snippet Previews Working (Misc)

Copyright © 2018 Ben Tasker | Sitemap | Privacy Policy
Available at snippets.bentasker.co.uk and snippets.6zdgh5a5e6zpchdz.onion