What FFmpeg is and why you need it in Command Prompt

FFmpeg is a free tool that converts, edits, and processes video and audio files from the command line. Once installed, you can type commands directly into Command Prompt (on Windows) or Terminal (on Mac/Linux) to resize videos, change formats, extract audio, trim clips, or combine multiple files — all without opening a graphical program.

The reason to install it specifically for Command Prompt use is speed and automation. Instead of clicking through a video editor five times, you write one command that does the job in seconds. If you need to process 50 videos the same way, you write the command once and run it 50 times.

This guide covers Windows installation. If you use Mac or Linux, the steps are similar but the file names and paths differ slightly.

Key Takeaways

  • Download the FFmpeg build from ffmpeg.org, not from random third-party sites, to avoid malware.
  • Extract the downloaded folder to a permanent location on your computer — not your Downloads folder, which you might empty later.
  • Add FFmpeg's location to your system PATH so Command Prompt can find it from any folder.
  • Test the installation by opening Command Prompt and typing ffmpeg -version — if you see version information, it worked.
  • Once installed, you run FFmpeg commands like ffmpeg -i input.mp4 output.avi directly from Command Prompt.

Download FFmpeg from the official source

Go to ffmpeg.org in your web browser. On the homepage, look for the Downloads section. Click the Windows icon to see Windows builds.

You will see several options. Download the full build labeled as a .zip file — it is usually the largest file listed and includes everything you need. Avoid "git" builds or "dev" builds unless you are a developer. The full build is what you want.

Save the .zip file to your Downloads folder or desktop. Do not open it yet.

Extract FFmpeg to a permanent location

Right-click the .zip file you downloaded and select Extract All. Windows will ask you where to put the extracted folder. Do not extract it to Downloads or Desktop — those folders are temporary. Instead, extract it to C:\Program Files or C:\ffmpeg.

If you do not have permission to write to Program Files, extract it to C:\Users\[YourUsername]\ffmpeg instead. Replace [YourUsername] with your actual Windows username.

After extraction, open File Explorer and navigate to the folder you just created. Inside, you should see a folder named something like ffmpeg-2024-01-15-full_build (the date will be different). Open that folder. Inside it, you should see a bin folder. This bin folder contains the actual ffmpeg.exe file that Command Prompt needs to find.

Add FFmpeg to your system PATH

Your system PATH is a list of folders that Command Prompt searches when you type a command. By adding FFmpeg's bin folder to the PATH, Command Prompt will know where to find ffmpeg.exe no matter what folder you are in.

Right-click This PC or My Computer on your desktop or in File Explorer, and select Properties. On the left side, click Advanced system settings. A window titled System Properties will open. Click the Environment Variables button near the bottom.

In the Environment Variables window, you will see two lists: User variables and System variables. In the System variables section, find the variable named Path and click it once to select it. Then click Edit.

A new window will open showing a list of paths. Click New and type the full path to your FFmpeg bin folder. If you extracted to C:\ffmpeg, type C:\ffmpeg\ffmpeg-2024-01-15-full_build\bin (use the actual folder name you see). If you extracted to your user folder, type C:\Users\[YourUsername]\ffmpeg\ffmpeg-2024-01-15-full_build\bin.

Click OK three times to close all the windows. You must close and reopen Command Prompt for the change to take effect.

Test that FFmpeg works in Command Prompt

Open Command Prompt. On Windows 10 or 11, press the Windows key, type cmd, and press Enter. A black window will open.

Type this command and press Enter:

ffmpeg -version

If FFmpeg is installed correctly, you will see text showing the FFmpeg version number and build information. If you see an error like "ffmpeg is not recognized as an internal or external command", the PATH was not set correctly. Go back to the Environment Variables step and check that you typed the path exactly right, with no extra spaces.

Run your first FFmpeg command

Now that FFmpeg is installed, you can use it to process media files. The basic structure of an FFmpeg command is:

ffmpeg -i input_file output_file

For example, to convert a video from MP4 to AVI format, you would type:

ffmpeg -i myvideo.mp4 myvideo.avi

To extract audio from a video as an MP3 file, type:

ffmpeg -i myvideo.mp4 -q:a 0 -map a audio.mp3

To resize a video to 1280x720 pixels, type:

ffmpeg -i myvideo.mp4 -s 1280x720 myvideo_resized.mp4

Before you run any command, make sure the input file is in the same folder as Command Prompt is currently looking at, or type the full path to the file. If your video is on your Desktop, you can navigate there by typing cd Desktop first.

Troubleshooting common installation problems

If Command Prompt still does not recognize ffmpeg after you set the PATH, restart your computer. Windows sometimes does not apply PATH changes until you restart.

If you extracted FFmpeg to a folder with spaces in the name (like "Program Files"), the PATH may not work. Re-extract it to a folder with no spaces, like C:\ffmpeg or C:\ffmpeg-build.

If you see an error about a missing DLL file when you run ffmpeg, your antivirus software may have quarantined part of FFmpeg. Check your antivirus quarantine folder, restore the file, and add the FFmpeg folder to your antivirus exclusion list.

If you downloaded FFmpeg from a website other than ffmpeg.org, delete it and download again from the official site. Third-party builds sometimes contain malware or are outdated.

Frequently Asked Questions

Do I need to install anything else to use FFmpeg?

No. FFmpeg is self-contained. Once you extract it and add it to your PATH, it works on its own. You do not need to install codecs, libraries, or other software separately.

Can I delete the original .zip file after extracting FFmpeg?

Yes. Once you have extracted the folder to its permanent location and tested it in Command Prompt, you can delete the .zip file. Keep the extracted folder itself — that is what FFmpeg needs to run.

What if I want to use FFmpeg from a specific folder only, not from Command Prompt everywhere?

You can skip the PATH step and instead copy the ffmpeg.exe file directly into the folder where your video files are. Then open Command Prompt in that folder and run your commands. This is slower if you work in many different folders, but it works without editing system settings.

How do I know what commands FFmpeg supports?

Type ffmpeg -h in Command Prompt to see basic help, or ffmpeg -h full for detailed options. You can also search for "FFmpeg [what you want to do]" online — the FFmpeg documentation and community forums have examples for almost every task.

Can I use FFmpeg on Mac or Linux?

Yes. On Mac, download the macOS build from ffmpeg.org and extract it the same way. On Linux, most distributions include FFmpeg in their package manager — type sudo apt install ffmpeg on Ubuntu or Debian, or the equivalent command for your distribution. The commands you run are identical across all three operating systems.