Skip to content
Back to Blog
How-To

How to Convert BMP to AVIF: 5 Free Methods in 2026

Jordan Webb·May 1, 20268 min read

Why Convert BMP to AVIF?

BMP (Bitmap Image File) is the oldest widely used image format still in active circulation. Developed by Microsoft in the late 1980s, BMP stores completely raw, uncompressed pixel data. No compression algorithm, no optimization — just pixels. A standard 1920×1080 screenshot in BMP format weighs approximately 6 MB. A larger diagram or legacy software export can run much higher.

AVIF (AV1 Image File Format) is the most advanced widely-supported image format available in 2026. Built on AV1 video codec technology, AVIF delivers compression that surpasses JPEG, PNG, and WebP simultaneously, while adding features like 10-bit color depth, HDR support, and film-grain synthesis. Converting BMP to AVIF is the single largest file size improvement you can make for any BMP image.

How much smaller? A typical 6 MB BMP screenshot becomes 150–500 KB as AVIF — a 90–97% reduction. AVIF lossy compression consistently outperforms WebP by 20–35% at equivalent visual quality. Even AVIF lossless produces files 80–85% smaller than BMP. No widely-supported format offers better compression from BMP.

Converting BMP to AVIF makes sense when you need:

  • Maximum compression: AVIF delivers 90–97% smaller files from BMP — more efficient than WebP (90–95%), PNG (60–80%), or JPG (70–80%).
  • 10-bit color depth: AVIF supports over a billion colors vs BMP's 16 million (8-bit). Smooth gradients that show banding in other formats render perfectly in AVIF.
  • HDR support: AVIF natively supports HDR and wide color gamut (P3, Rec. 2020). For BMP files from professional imaging software, this preserves color fidelity that other web formats cannot match.
  • Web delivery: AVIF has approximately 94% global browser support as of 2026, including all modern versions of Chrome, Firefox, Safari, and Edge.
  • Google PageSpeed compliance: Google Lighthouse flags BMP files and recommends serving next-generation formats. AVIF directly resolves this warning — and produces even smaller files than WebP.
  • If your BMP files will be edited further or used in design software, BMP to PNG is the better choice — PNG has universal software support and is lossless. For the smallest possible files headed to a website or app, AVIF wins decisively.

    For the broader question of which format is best for the web, see our AVIF vs WebP vs JPEG comparison.

    AVIF Quality Settings: CRF Explained

    Unlike WebP (which uses a 0–100 quality scale), AVIF tools typically use a CRF (Constant Rate Factor) scale where lower numbers mean higher quality. Understanding this prevents common mistakes:

    CRF ValueVisual QualityFile Size vs BMPBest Use Case
    10–20Excellent, near-lossless85–95% smallerArchival, professional delivery
    20–30Very high, imperceptible loss90–97% smallerWeb photos, product images
    30–40High, minor artifacts at 100%93–98% smallerThumbnails, background images
    40–55Visible degradation95–99% smallerHeavy compression, not recommended
    63Worst quality (lossless is separate)variesAvoid

    Practical recommendation: CRF 24–28 is the sweet spot for most BMP-to-AVIF conversions. It delivers visually indistinguishable quality from the original BMP while achieving 92–97% file size reduction. For screenshots and graphics with sharp edges and flat colors, use CRF 20–24 or lossless mode.

    For FFmpeg specifically, the encoder speed is controlled with -cpu-used (0=slowest/best, 8=fastest/roughest). For web delivery, -cpu-used 4 balances quality and build time well.

    Method 1: Convert BMP to AVIF in Your Browser (No Upload Required)

    The fastest and most private method is a browser-based converter that processes your files entirely on your device. PhotoFormatLab's BMP to AVIF converter uses WebAssembly to convert BMP files locally — your images never leave your computer.

    Step-by-step:

  • Open photoformatlab.com/bmp-to-avif in your browser
  • Drag and drop your BMP files onto the drop zone, or click to select files
  • Multiple files can be selected for batch conversion
  • Click Convert — processing happens entirely in your browser tab
  • Download individual AVIF files or click Download as ZIP for all files at once
  • Why browser-based conversion matters for BMP files:

    BMP files commonly originate from internal business software, legacy Windows applications, medical imaging systems, and screenshot tools. Uploading these files to server-based converters like Convertio, CloudConvert, or FreeConvert means your files transit to third-party servers — outside your control and potentially subject to retention policies.

  • 100% private: All conversion runs in your browser using WebAssembly. Zero server contact, zero uploads.
  • No file size caps: Convert large uncompressed BMP files (which can be tens of megabytes) without hitting upload limits.
  • Batch support: Drop multiple BMP files and convert them all at once.
  • No signup required: No account, no email, no subscription.
  • For a full explanation of why browser-based conversion is safer than uploading, see our guide on converting images without uploading to a server.

    Method 2: FFmpeg — Best Compression Control

    FFmpeg is the most versatile media processing tool available across all platforms. It uses the libaom encoder for AVIF, which produces the best compression of any open-source AVIF encoder.

    Install FFmpeg:

  • macOS: brew install ffmpeg
  • Linux (Debian/Ubuntu): sudo apt install ffmpeg
  • Windows: Download from ffmpeg.org and add to your PATH
  • Convert a single BMP to AVIF (recommended quality):

    ```bash

    ffmpeg -i input.bmp -c:v libaom-av1 -crf 28 -cpu-used 4 output.avif

    ```

    Lossless AVIF with FFmpeg:

    ```bash

    ffmpeg -i input.bmp -c:v libaom-av1 -crf 0 -cpu-used 4 output.avif

    ```

    Batch convert all BMP files in a directory:

    ```bash

    mkdir -p avif-output

    for f in *.bmp; do

    ffmpeg -i "$f" -c:v libaom-av1 -crf 28 -cpu-used 4 avif-output/"${f%.bmp}.avif"

    done

    ```

    Batch with higher quality (CRF 20):

    ```bash

    mkdir -p avif-output

    for f in *.bmp; do

    ffmpeg -i "$f" -c:v libaom-av1 -crf 20 -cpu-used 4 avif-output/"${f%.bmp}.avif"

    done

    ```

    Note: AVIF encoding with libaom is CPU-intensive compared to JPG or WebP. On modern hardware, expect 1–5 seconds per image at -cpu-used 4. Using -cpu-used 6 or -cpu-used 8 speeds this up significantly at a modest quality trade-off — fine for bulk thumbnail generation.

    Method 3: ImageMagick (Windows, Mac, Linux)

    ImageMagick converts BMP to AVIF with simpler syntax than FFmpeg. Install via the ImageMagick website or on macOS with brew install imagemagick.

    Convert a single file (ImageMagick 7):

    ```bash

    magick input.bmp -quality 60 output.avif

    ```

    Note: ImageMagick's -quality scale for AVIF maps differently than WebP. Quality 60 corresponds roughly to CRF 28 (good web quality). Quality 80 = CRF 20 (high quality). Quality 100 = near-lossless.

    Batch convert all BMP files:

    ```bash

    mkdir -p avif-output

    for file in *.bmp; do

    magick "$file" -quality 60 avif-output/"${file%.bmp}.avif"

    done

    ```

    Fast batch using mogrify:

    ```bash

    mkdir -p avif-output

    magick mogrify -format avif -quality 60 -path avif-output *.bmp

    ```

    ImageMagick is the most convenient option when you need to combine conversion with other transformations — resize the image, apply sharpening, or adjust color profiles — all in a single command.

    Method 4: Python Pillow

    Pillow supports AVIF encoding on all platforms and is ideal for automated conversion pipelines, CI/CD workflows, or any scenario where BMP-to-AVIF is part of a larger processing chain.

    Install Pillow:

    ```bash

    pip install Pillow

    ```

    Note: AVIF support in Pillow requires libavif to be installed on the system. On macOS: brew install libavif. On Linux: sudo apt install libavif-dev.

    Convert a single BMP to AVIF:

    ```python

    from PIL import Image

    with Image.open('input.bmp') as img:

    img.save('output.avif', 'AVIF', quality=60)

    ```

    Batch convert with CMYK guard:

    ```python

    from PIL import Image

    import os

    def convert_bmp_to_avif(input_dir, output_dir, quality=60):

    os.makedirs(output_dir, exist_ok=True)

    for filename in os.listdir(input_dir):

    if filename.lower().endswith('.bmp'):

    input_path = os.path.join(input_dir, filename)

    output_path = os.path.join(

    output_dir,

    os.path.splitext(filename)[0] + '.avif'

    )

    try:

    with Image.open(input_path) as img:

    if img.mode not in ('RGB', 'RGBA'):

    img = img.convert('RGB')

    img.save(output_path, 'AVIF', quality=quality)

    print(f'Converted: {filename}')

    except Exception as e:

    print(f'Error converting {filename}: {e}')

    convert_bmp_to_avif('./bmp_files', './avif_files', quality=60)

    ```

    The color mode guard converts CMYK BMP files (common from professional print workflows) and unusual palette-mode BMPs to RGB before encoding. AVIF requires RGB or RGBA input.

    Method 5: Squoosh (Browser — Single Files)

    Squoosh is Google's browser-based image optimization tool. It processes files locally (no uploads) and gives manual control over AVIF quality with a live preview comparison.

    Steps:

  • Open squoosh.app in Chrome or Edge
  • Drag your BMP file onto the Squoosh window
  • In the right panel, select AVIF from the codec dropdown
  • Adjust the quality slider while comparing the before/after preview
  • Click the download icon to save your AVIF file
  • Squoosh is best for single-file conversions where you want to visually compare quality levels before committing. For batch conversions, use PhotoFormatLab (Method 1) or the command-line methods above.

    BMP vs AVIF: Feature Comparison

    FeatureBMPAVIF
    CompressionNone (raw pixels)Lossless or lossy
    Typical file size (1080p screenshot)6 MB150–500 KB
    Size reduction vs BMP90–97%
    Color depth8-bit (16M colors)10-bit (1B+ colors)
    HDR / wide color gamutNoYes (P3, Rec. 2020)
    Transparency (alpha)Limited (BMP32 only)Full alpha channel
    Browser supportNo web support~94% global (2026)
    Animation supportNoYes (animated AVIF)
    Google PageSpeed friendlyNoYes (recommended)
    Compression vs WebP20–35% smaller than WebP
    Platform compatibilityWindows-primaryUniversal (web)
    Design tool supportMost toolsGrowing (Chrome, Figma)

    Key takeaways:

  • AVIF achieves 10–40x smaller files compared to BMP
  • AVIF's 10-bit color depth surpasses BMP's 8-bit — richer gradients, no banding
  • AVIF beats WebP by 20–35% at equivalent visual quality — the best compression from BMP
  • AVIF resolves Google Lighthouse's "Serve images in next-gen formats" warning
  • BMP has no web browser support; AVIF works in all modern browsers
  • BMP to AVIF vs BMP to WebP vs BMP to PNG

    Choosing the right output format from BMP depends on your destination and use case:

    Convert BMP to AVIF when:

  • Images are destined for a modern website or app where you want maximum compression
  • You want the smallest possible files with the best quality-to-size ratio
  • The BMP contains photographs or complex gradients that benefit from AVIF's 10-bit color
  • You are targeting modern browsers (Chrome, Firefox, Safari 16+, Edge)
  • Convert BMP to WebP when:

  • You need slightly broader browser compatibility (97% vs AVIF's 94%)
  • The tool or CMS you're using supports WebP but not yet AVIF
  • You need animated output (animated WebP is more widely supported than animated AVIF)
  • Convert BMP to PNG when:

  • The images will be used in design software (Photoshop, Affinity, Figma, GIMP)
  • You need universal compatibility with all tools and platforms
  • The images will be edited further after conversion and you need a lossless editing format
  • For more detail on the BMP to WebP conversion path, see our BMP to WebP guide. For lossless archiving decisions, see BMP to PNG.

    Transparency in BMP to AVIF Conversion

    Standard 24-bit BMP files have no alpha channel. Converting one of these to AVIF produces a fully opaque image — the background color in the BMP is preserved exactly. Transparency is not added automatically.

    If you need transparency in the output:

  • Open the BMP in GIMP (free) or Photoshop
  • Remove the background and export directly as AVIF, or save as PNG with transparency
  • Convert the transparent PNG to AVIF using PhotoFormatLab's PNG to AVIF converter
  • 32-bit BMP files with alpha: Some Windows applications (notably legacy video and imaging tools) save 32-bit BMP with an embedded alpha channel. FFmpeg and ImageMagick both preserve this alpha channel when encoding to AVIF. PhotoFormatLab's browser-based converter also handles 32-bit BMPs with alpha correctly.

    Frequently Asked Questions

    Does converting BMP to AVIF lose quality?

    It depends on whether you use lossless or lossy AVIF. Lossless AVIF preserves every pixel from the BMP source exactly — zero quality loss, just dramatically smaller files. Lossy AVIF (CRF 24–28 in FFmpeg, quality 55–65 in ImageMagick) is visually indistinguishable from the original for most image types, including photographs and screenshots. AVIF's perceptual compression is particularly strong: at the same visual quality as WebP, AVIF files are 20–35% smaller. Always keep the source BMP if you need to re-export at a different quality later.

    How much smaller will my AVIF file be compared to BMP?

    For typical BMP files:

  • Lossless AVIF: 80–85% smaller than BMP
  • Lossy AVIF at CRF 28: 92–96% smaller than BMP
  • Lossy AVIF at CRF 35: 94–98% smaller
  • A 6 MB BMP screenshot typically becomes 100–400 KB as AVIF. Complex photographs with many colors and fine details compress less than flat graphics or screenshots. For comparison, the same image as WebP at equivalent quality is typically 20–35% larger than the AVIF version.

    Is it safe to convert BMP files to AVIF online?

    With PhotoFormatLab, yes — completely safe. All conversion runs in your browser using WebAssembly; your BMP files never leave your device. Server-based converters like Convertio, CloudConvert, and FreeConvert upload your files to remote servers, which is a real privacy risk for BMP files that may contain internal screenshots, scanned business documents, proprietary graphics, or sensitive system exports. Read our guide on whether online image converters are safe for a full breakdown.

    What browsers support AVIF in 2026?

    AVIF has approximately 94% global browser support as of 2026. All modern versions of Chrome (85+), Firefox (93+), Safari (16+), and Edge (121+) support AVIF natively. Internet Explorer does not support AVIF, but it is no longer supported by Microsoft. For the small percentage of users on older browsers, you can serve a WebP or JPG fallback using the HTML element. See our AVIF format guide for the full browser compatibility table.

    Can I batch convert BMP files to AVIF?

    Yes. PhotoFormatLab's BMP to AVIF converter accepts multiple files simultaneously and provides a ZIP download for the results — all processed privately in your browser. The bash loop examples in Methods 2 and 3 convert entire directories of BMP files. Python Pillow (Method 4) is ideal for automated pipelines where BMP-to-AVIF conversion is part of a larger workflow, such as a CMS image processing script or a CI/CD image optimization step.

    Why is AVIF encoding slow compared to JPG or WebP?

    AVIF uses the AV1 video codec as its compression engine, which is computationally heavier than the algorithms used by JPEG or WebP. The libaom encoder in FFmpeg in particular is designed for maximum compression efficiency, not encoding speed. For bulk conversions, use -cpu-used 6 or -cpu-used 8 in FFmpeg to speed things up at a modest quality trade-off. Alternatively, the browser-based PhotoFormatLab converter uses an optimized WebAssembly build that balances quality and speed for typical BMP file sizes.

    J
    Jordan Webb·Founder, PhotoFormatLab

    Jordan builds privacy-focused web tools. He created PhotoFormatLab to make image conversion free, instant, and fully browser-based — no file uploads, no accounts, no watermarks. About PhotoFormatLab →

    Ad
    Ad