Double audio volume (or any multiplier) with the volume filter
The volume filter applies a fixed gain in decibels (or as a linear multiplier) to the audio. The most common uses are boosting a quiet recording, attenuating a too-loud one, or applying a fixed gain to a batch of files.
The command
ffmpeg -i input.mp4 -filter:a "volume=2.0" -c:v copy output.mp4What it does
The argument is a linear multiplier: 2.0 is double the amplitude, 0.5 is half, 1.0 is unchanged. The filter multiplies every sample by the value, which adds 20 * log10(value) dB to the perceived loudness. 2.0 adds 6.02 dB; 0.5 subtracts 6.02 dB.
When to use it
For a fixed gain adjustment to a single file. The audio filter defaults to linear multiplier; for dB, use the volume=XdB form. For precise loudness matching across many files, use loudnorm instead, which normalizes to a target LUFS rather than a fixed gain.
Video and audio requirements
Any decodable audio. The -c:v copy preserves the video without re-encoding. Note that a multiplier of 2.0 on a source with peaks at 0 dBFS produces output with peaks at +6 dBFS, which clips in any integer audio format (WAV, AAC, MP3). Normalize first or use a limiter.
Things to avoid
- Boosting a source that is already at 0 dBFS. The output will clip and distort. Normalize first, or use a limiter (
alimiter) after the volume filter to cap the peaks. - Using a multiplier when you mean decibels. The two are easy to confuse.
volume=2.0is +6 dB;volume=6dBis the same;volume=2dBis much less boost (only +2 dB). - Combining with
-c:a copy. Stream copy on audio is incompatible with a filter; the audio must be re-encoded if you applyvolume. - Forgetting that the filter applies to the audio stream only. The video is unaffected, but if you forget the
-c:v copy(or another-c:v), the video is re-encoded unnecessarily.