To batch convert videos on Windows, use either a converter with a job queue - add a folder of files, choose one preset, and let it work through them - or a short FFmpeg loop in Command Prompt or PowerShell. Both approaches encode each file in turn with the same settings and save the results to a separate folder, so your originals stay untouched.
Below we cover the FFmpeg one-liners for Command Prompt and PowerShell, how to choose settings that suit a whole batch rather than one clip, and the practical problems that come up when converting hundreds of files: naming, failures, disk space and running jobs in parallel.
Before you start: decide what the batch is for
A batch only works well if one set of settings suits every file in it. Group your files by goal first:
- Making files smaller - H.265 or AV1 with a constant quality setting (CRF) is usually the best fit, since every file gets the same visual quality regardless of length. Our guide to what CRF means explains how to pick a value.
- Compatibility - H.264 video with AAC audio in MP4 plays on almost anything.
- Changing container only - if the codecs are already fine and you just need MP4 instead of MKV or MOV, remux with stream copy. It is lossless and takes seconds per file.
- Editing - convert to an intermediate codec such as ProRes or DNxHR.
Mixed sources need a little care. If a folder contains some 4K HDR footage and some old standard-definition clips, a single preset that scales to 1080p will upscale the old clips. Use rules such as "only downscale" or split the batch.
Batch converting with FFmpeg in Command Prompt
Open Command Prompt in the folder that holds your videos (type cmd in File Explorer's address bar), create an output folder, and run:
for %i in (*.mov) do ffmpeg -i "%i" -c:v libx264 -crf 20 -preset medium -c:a aac -b:a 160k "converted\%~ni.mp4"
%~ni is the file name without its extension, so holiday.mov becomes converted\holiday.mp4. If you save the command in a .bat file, double the percent signs: %%i and %%~ni.
To remux a folder of MKV files to MP4 without re-encoding:
for %i in (*.mkv) do ffmpeg -i "%i" -map 0:v -map 0:a -c copy "converted\%~ni.mp4"
The explicit -map options skip subtitle tracks, because MP4 cannot hold most MKV subtitle formats (such as ASS or PGS) and the whole job would fail otherwise. See MKV vs MP4 for the differences.
Batch converting with PowerShell
PowerShell handles subfolders and spaces in names more gracefully:
Get-ChildItem -Recurse -Include *.mp4,*.mov | ForEach-Object { ffmpeg -n -i $_.FullName -c:v libx265 -crf 24 -c:a copy ("D:\out\" + $_.BaseName + ".mkv") }
The -n flag tells FFmpeg never to overwrite an existing output file, which is useful if you re-run the command after stopping partway through. Be aware that this example writes everything into one folder, so two files with the same name in different subfolders would collide; the -n flag prevents the second from overwriting the first, but it will be skipped.
Common batch problems and how to avoid them
One bad file stops everything
A plain loop carries on after a failure, but it will not tell you which files failed unless you log the output. Redirect each run's log to a file, or use a tool with a queue that records failures and lets you retry them.
Partial files that look finished
If the PC restarts mid-encode, you are left with a truncated output file that has the right name. On the next run, -n will skip it as if it were complete. Writing to a temporary name and renaming on success avoids this, as does checking durations afterwards.
Running out of disk space
A batch of camera footage can easily need hundreds of gigabytes. Estimate output size first - with CRF the size varies by content, so encode a sample - and keep the output on a drive with plenty of room.
Running several jobs at once
Software encoders such as x264 and x265 already use many CPU threads, so running two at once rarely doubles throughput and can slow both down. It can make sense, though, to run one GPU encode alongside one CPU encode, since they use different hardware. GPU encoders have session limits on some consumer cards, so check before queuing many parallel NVENC jobs. Our guide to GPU encoding on NVIDIA, Intel and AMD covers the trade-offs.
Audio and subtitle tracks
By default FFmpeg selects one video and one audio stream. If your sources contain several audio languages or commentary tracks, add -map 0 to keep everything, then remove what the output container cannot hold.
A quick checklist for large batches
- Test your settings on two or three representative files and check them on the devices that will play them.
- Write outputs to a separate folder - never back over the originals.
- Use a naming pattern that cannot collide, such as adding a suffix like
_h265. - Log results and check for failures and suspiciously small outputs.
- Spot-check durations and play the start, middle and end of a few files.
- Only delete originals once you are satisfied, if at all.
If new files arrive regularly, consider automating the whole thing with a watch folder instead of running batches by hand.
Doing it with Movie Encoder
Movie Encoder has a batch queue built for this: drag in files or scan whole folders, apply a preset, and queue hundreds or thousands of jobs that are saved between sessions. Each job can have its own settings and destination, priorities can be changed, and jobs can be paused, cancelled or retried. Several jobs can run at once within CPU and GPU limits, output naming templates and collision-safe names prevent overwrites, and the queue recovers after a crash.
Encodes are written to a temporary file and only moved into place after they finish and pass a check, so a partial encode is never marked complete, and originals are never overwritten or deleted. Progress shows the real percentage, frames, fps, speed and output size, and the expert console can export the job as a Windows batch file if you would rather run it yourself.
Frequently asked questions
Can I batch convert videos without losing quality?
Yes, if you only need a different container, remux with stream copy, which keeps the original streams untouched. Any re-encode with a lossy codec loses some quality, though a sensible CRF value keeps the loss hard to see.
Is it faster to run several conversions at once?
With CPU encoders, usually not by much, because x264 and x265 already use most of your cores. Pairing one GPU encode with one CPU encode is more likely to raise total throughput.
How do I batch convert files in subfolders?
In PowerShell, use Get-ChildItem with the -Recurse switch and pipe each file to FFmpeg. Make sure the output names cannot collide when files in different folders share a name.
