Black Friday40% off all plans

JFIF to JPG: What a JFIF File Is and How to Convert It on Mac

By Hieu Dinh

JFIF to JPG: The Short Answer

A JFIF to JPG conversion is usually just a rename. A .jfif file is already a JPEG: same codec, same image data, different extension. On a Mac, select the file in Finder, press Return, change .jfif to .jpg and click Use .jpg. The image doesn't change at all, and every app that accepts JPGs will now open it.

For a whole folder, one Terminal line renames every file:

for f in *.jfif; do mv -n -- "$f" "${f%.*}.jpg"; done

The rest of this guide explains what JFIF actually is, why Windows and Chrome keep saving images with that extension, the other ways to convert (Preview, sips, FFmpeg, ImageMagick), when JFIF to PNG makes sense, and how to stop the .jfif downloads at the source.


What Is a JFIF File?

JFIF stands for JPEG File Interchange Format. The original JPEG standard defines how to compress an image, but it left details like color space and pixel density loose. JFIF filled in those gaps so that a JPEG made on one system would display correctly on another. Version 1.02 was published in 1992 and became the de facto standard; it was formally standardized in 2011 as ITU-T Recommendation T.871 (and later as ISO/IEC 10918-5).

So "JFIF vs JPG" isn't really a comparison. JPEG is the compression method; JFIF is the file layout that most JPEG images use; .jpg, .jpeg and .jfif are just extensions for those files. They all share the same MIME type, image/jpeg.

You can see this on any Mac. We made a JPEG with FFmpeg, copied it to photo.jfif, and ran file on both:

file photo.jpg photo.jfif
photo.jpg:  JPEG image data, JFIF standard 1.02, ... 1920x1080, components 3
photo.jfif: JPEG image data, JFIF standard 1.02, ... 1920x1080, components 3

Identical. The first bytes of the file show the marker that gives the format its name: a JPEG start-of-image marker (FF D8), then an APP0 segment containing the ASCII text JFIF:

xxd -l 16 photo.jfif
# 00000000: ffd8 ffe0 0010 4a46 4946 0001 0200 0001  ......JFIF......

JFIF vs Exif JPEG

Photos straight from a camera or iPhone usually use Exif, a different header (APP1) that stores camera settings, date and GPS location. Exif and JFIF are two ways of wrapping the same JPEG image data, and plenty of files carry both. When we re-saved our test file with macOS sips, the output had a JFIF 1.01 header and an Exif block. Either way it's a normal JPEG. If you're worried about location data in photos you share, see our guide to removing EXIF data.

Where JFIF files come from

  • Saving images from the web on Windows. By far the most common source; see the next section.
  • Files sent by Windows users: email attachments, shared drives, Slack and Discord uploads that were saved as .jfif on a PC first.
  • Some websites and apps that serve or export JPEGs with a .jfif name.

On a Mac, browsers normally save JPEGs as .jpg, so if you have .jfif files, they almost always started life on a Windows machine.


Why Does My Browser Download Images as JFIF?

When you save an image, the browser knows its content type (image/jpeg) and asks the operating system which extension goes with it. On Windows, that answer comes from the registry:

HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/jpeg
    Extension = .jfif

On many PCs this Extension value is .jfif instead of .jpg. Users and IT forums have reported it since around 2018, often appearing after a Windows 10 update, and it can also be changed by software that registers itself for JPEG files. Chrome and Edge follow the registry, so "Save image as" suggests .jfif for every JPEG.

Mozilla hit the same problem and decided it was bad registry data rather than a choice users wanted: Firefox 81 stopped using .jfif as the default extension for image/jpeg on Windows. Chrome and Edge still read the registry, so the fix for them is on the Windows side (covered at the end of this guide).

The important point for a Mac user: nothing is wrong with the image. The file was named after a technical spec instead of the usual extension, and that's all.


Why Your Mac Struggles with .jfif

macOS identifies files by extension through Uniform Type Identifiers, and it has no type registered for .jfif. You can check with Spotlight's metadata tool:

mdls -name kMDItemContentType photo.jfif
# kMDItemContentType = "dyn.ah62d4rv4ge80y3xmq2"

That dyn. value is what macOS assigns to an extension it doesn't recognise. The file is treated as generic data rather than an image, which is why a .jfif may show a blank document icon, why double-clicking may not open Preview, and why upload forms, Photos and many Mac apps won't accept it. Rename it to .jpg and macOS sees public.jpeg and everything works.

The underlying image decoder is fine with the content. sips reads a .jfif without complaint:

sips -g format -g pixelWidth photo.jfif
#   format: jpeg
#   pixelWidth: 1920

Method 1: Convert JFIF to JPG on Mac by Renaming (Lossless)

This is the best method because it's instant and changes nothing in the image.

  1. In Finder, turn on extensions so you can see them: Finder > Settings > Advanced > Show all filename extensions.
  2. Select the .jfif file and press Return (or right-click and choose Rename).
  3. Replace jfif with jpg and press Return.
  4. Finder asks whether you want to change the extension. Click Use .jpg.

To rename many files from Finder, select them all, right-click and choose Rename [N] Items. Choose Replace Text, find .jfif, replace with .jpg, and click Rename. Finder may ask you to confirm the extension change. Try it on a couple of copies first if you haven't used it before.

We checked that renaming is truly lossless: after renaming, cmp reported the .jpg as byte-for-byte identical to the original JPEG. Any tool that "converts" JFIF to JPG by re-encoding does extra work and, as the next sections show, usually makes the file bigger.


Method 2: Batch Convert JFIF to JPG in Terminal

For a folder full of downloads, Terminal is faster than Finder. cd into the folder (type cd , drag the folder onto the Terminal window, press Return), then run:

for f in *.[jJ][fF][iI][fF]; do mv -n -- "$f" "${f%.*}.jpg"; done

What it does:

  • *.[jJ][fF][iI][fF] matches .jfif, .JFIF and mixed case.
  • "${f%.*}.jpg" swaps the extension and keeps the rest of the name, including spaces.
  • -n stops mv from overwriting a .jpg that already exists with the same name.

We tested it in zsh (the default macOS shell) on files named Image one.jfif, b.JFIF and c.jfif; all three came out as .jpg with identical bytes. If the folder has no .jfif files, zsh just prints "no matches found" and does nothing.

To include subfolders, use find:

find . -type f -iname '*.jfif' -exec sh -c 'mv -n -- "$1" "${1%.*}.jpg"' _ {} \;

For more folder-wide recipes, see our guide to batch converting images on Mac.


Method 3: Re-Save the JFIF as JPG with Preview or sips

Sometimes you want a fresh JPEG anyway, for example to set a lower quality and make the file smaller in the same step.

Preview

  1. Right-click the .jfif and choose Open With > Preview. (If Preview isn't listed or refuses the file, rename it to .jpg first, as above.)
  2. Choose File > Export.
  3. Set Format to JPEG, adjust the Quality slider, and save.

sips

sips is built into macOS. For a single file, give the output a .jpg name:

sips -s format jpeg -s formatOptions 85 photo.jfif --out photo.jpg

formatOptions takes low, normal, high, best or a number from 0 to 100.

To re-encode a whole folder, loop over the files so each output gets a .jpg name:

for f in *.jfif; do sips -s format jpeg -s formatOptions 85 "$f" --out "${f%.*}.jpg"; done

Watch out for one sips quirk. If you point --out at a folder instead of a file name, sips writes a re-encoded JPEG but keeps the .jfif extension:

sips -s format jpeg *.jfif --out converted/
# converted/ now contains x.jfif, y.jfif ... still .jfif

That's the one case where it doesn't help at all. (When converting to PNG, sips does change the suffix and prints "Output file suffix changed to png".)

Re-encoding has a cost

Re-saving a JPEG decodes it and compresses it again, which adds a little more compression loss. It also doesn't guarantee a smaller file. In our tests:

Source (.jfif)OutputSize
98 KB synthetic 1080p imageRenamed to .jpg98 KB (identical)
98 KB synthetic 1080p imagesips, default quality113 KB
98 KB synthetic 1080p imagesips, quality best211 KB
1.07 MB noisy photo-like 1080p imagesips, quality 901.51 MB

So only re-encode when you actually want to change the quality or size. If a smaller JPEG is the goal, our guides on how to compress a JPEG and compressing JPG files cover the settings that matter.


Method 4: FFmpeg or ImageMagick

If you already have these tools from Homebrew, both read .jfif files directly.

ImageMagick:

magick photo.jfif photo.jpg
magick photo.jfif photo.png

To convert every JFIF in a folder to PNG in one go:

magick mogrify -format png *.jfif

mogrify -format writes new files alongside the originals rather than overwriting them.

FFmpeg:

ffmpeg -i photo.jfif -q:v 2 photo.jpg
ffmpeg -i photo.jfif photo.png

For JPEG output, -q:v runs from 2 (best) to 31 (worst). Both tools re-encode when writing a JPEG, so the same advice applies: rename when you just need the right extension.

Online converters

Sites like Zamzar, FreeConvert and Convertio offer JFIF to JPG conversion. They work, but they upload your image to a server to do what a rename does locally. For personal photos, scans or anything with location data, stay on your Mac.


JFIF to PNG: When It Makes Sense

JFIF to PNG is the second most common request, usually because an app, game mod tool or upload form only accepts PNG. On a Mac:

sips -s format png photo.jfif --out photo.png

Or in Preview: File > Export, Format: PNG.

Before you convert, know what PNG does and doesn't give you:

  • No quality gain. PNG is lossless, so it preserves the image exactly as it looks now, but it can't restore detail the JPEG compression already discarded.
  • No transparency. JPEG has no alpha channel, so the PNG will be fully opaque. Removing a background is a separate editing step.
  • Much bigger files. In our tests, a 98 KB JFIF became a 468 KB PNG (4.8x), and a 1.07 MB photo-like JFIF became a 4.8 MB PNG (4.5x).

If a tool accepts JPG, rename instead. If you need a modern format that's smaller than JPEG, WebP or AVIF are better targets than PNG; see best image format for websites and what is AVIF. Our JPEG vs PNG comparison explains when each format is the right choice, and the reverse trip is covered in PNG to JPG.


How to Stop Windows from Saving Images as JFIF

If you (or the person sending you files) use Windows, fix the cause so new downloads save as .jpg:

  1. Press Win + R, type regedit and press Enter.
  2. Back up first: File > Export, save a copy of the registry.
  3. Go to HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/jpeg.
  4. Double-click the Extension value and change .jfif to .jpg.
  5. Close Registry Editor and restart the browser.

Some users report that major Windows updates set the value back to .jfif, so check it again if the problem returns.

If editing the registry isn't an option (on a managed work PC, for instance), there are two workarounds: switch to Firefox, which ignores the .jfif mapping, or simply type .jpg over the extension in the Save dialog.


Converting JFIF to JPG on Windows and iPhone

Quick pointers if the files aren't on your Mac yet:

  • Windows: In File Explorer, turn on View > Show > File name extensions, then rename .jfif to .jpg. Or open the file in Paint and use File > Save as > JPEG picture.
  • iPhone and iPad: In the Files app, long-press the file, tap Rename, and change the extension. If Files hides extensions, rename it after moving it to your Mac instead.

If iPhone photos are what you're converting, the format is usually HEIC rather than JFIF; see convert HEIC to JPG on iPhone and HEIC vs JPEG.


Where Compresto Fits

Compresto doesn't recognise the .jfif extension, because macOS itself has no file type for it. Drop a .jfif in and it won't be treated as an image. Rename the files to .jpg first (Method 1 or 2 above); that's the actual JFIF to JPG step.

After that, Compresto is useful for what usually comes next. It's a native Mac app that compresses images, videos, GIFs and PDFs in batches, entirely on your Mac, with nothing uploaded. For a folder of renamed downloads, it can:

  • Compress the JPGs in one pass, with an optional target file size for upload forms with limits.
  • Convert them to PNG, WebP or AVIF in batch, if a site or tool wants a different format. WebP and AVIF are typically much smaller than JPEG at similar quality; see WebP to JPG for the other direction and our JPEG XL overview for where newer formats stand.
  • Resize large images in the same pass.

Frequently Asked Questions

Is JFIF the same as JPG?

Yes, for practical purposes. JFIF (JPEG File Interchange Format) is the file layout most JPEG images use, and .jpg is the usual extension for those files. A .jfif file contains the same JPEG-compressed image data as a .jpg; only the extension is different. Renaming it to .jpg doesn't change a single byte of the image.

How do I convert JFIF to JPG on a Mac?

Select the file in Finder, press Return, change .jfif to .jpg and click Use .jpg when Finder asks. That's a complete, lossless conversion. For a folder, run for f in *.jfif; do mv -n -- "$f" "${f%.*}.jpg"; done in Terminal. Re-encoding with Preview or sips also works but recompresses the image for no benefit.

Why does my browser download images as JFIF?

On Windows, browsers ask the system which extension belongs to the image/jpeg content type. That answer lives in the registry under HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/jpeg, in a value called Extension. On some PCs it's set to .jfif, so Chrome and Edge suggest .jfif when you save a JPEG. Firefox has ignored that setting since version 81.

How do I stop Windows from saving images as JFIF?

Open Registry Editor, go to HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/jpeg, double-click the Extension value and change .jfif to .jpg. Restart the browser. Back up the registry first, and check the value again after major Windows updates, because some users report it being set back to .jfif.

Does converting JFIF to JPG lose quality?

Not if you rename the file. The image data is already JPEG, so changing the extension is lossless and instant. Exporting through Preview, sips or an online converter decodes and re-encodes the JPEG, which adds a small amount of new compression loss and often makes the file larger.

Should I convert JFIF to PNG?

Only if a tool specifically needs a PNG. PNG is lossless, so the conversion keeps the image exactly as it looks now, but it can't restore detail the JPEG compression already removed, and the file gets much bigger. In our test a 1 MB photo-like JFIF became a 4.8 MB PNG. JPEG has no transparency, so there's no alpha channel to gain either.


The Short Version

A JFIF file is a JPEG with a less common extension, usually created when Chrome or Edge on Windows follows a registry setting that maps image/jpeg to .jfif. To convert JFIF to JPG on a Mac, rename the file: it's instant and lossless. Use a Terminal loop for whole folders, re-encode with Preview or sips only when you also want to change quality, and convert to PNG only when a tool demands it. To stop it happening, change the Extension value in the Windows registry to .jpg.

Download Compresto for Mac →


Ready to compress your files? Join thousands of creators using Compresto ⚡