Quick Verdict
Use JPG when…
Use .jpg — it's shorter and more common. Windows, macOS, and most cameras default to .jpg. Most web servers serve both identically.
Use JPEG when…
Use .jpeg if a specific tool, CMS, or API explicitly requires it, or if you're on a system that historically used .jpeg. The file content is identical.
JPG vs JPEG: Feature Comparison
| Feature | JPG | JPEG |
|---|---|---|
| File format | JPEG compression | JPEG compression (identical) |
| File content | Identical to .jpeg | Identical to .jpg |
| Extension length | 3 characters (MS-DOS compatible) | 4 characters |
| Camera default | Most cameras use .jpg | Some cameras use .jpeg |
| Web standard | More common on the web | Less common but valid |
| macOS default | Preview saves as .jpg | Some tools use .jpeg |
| MIME type | image/jpeg | image/jpeg (same) |
| Can rename safely? | Yes — renaming .jpg to .jpeg is safe | Yes — renaming .jpeg to .jpg is safe |
When JPG wins
- ✓File format: JPEG compression
- ✓File content: Identical to .jpeg
- ✓Extension length: 3 characters (MS-DOS compatible)
When JPEG wins
- ✓File format: JPEG compression (identical)
- ✓File content: Identical to .jpg
- ✓Extension length: 4 characters
Frequently asked questions
Can I rename .jpg to .jpeg or vice versa?
Yes — completely safe. The file extension is just metadata; the actual image data inside is identical. Rename .jpg to .jpeg or .jpeg to .jpg freely with no effect on quality or compatibility. Your OS may warn you about changing the extension, but the file will open correctly.
Why does my camera save as .JPG instead of .JPEG?
Cameras inherited the .jpg convention from the MS-DOS era of the 1990s, when three-character extensions were the rule. The convention stuck. Every camera manufacturer uses .jpg as the default. .jpeg is equally valid and contains identical data.
Does a web server care if an image is .jpg or .jpeg?
Not for serving the file — both extensions serve with the image/jpeg MIME type. However, case matters on Linux servers: photo.jpg and photo.jpeg are two different files. Make sure your HTML references the correct filename and extension, and be consistent in your naming convention.
Ready to convert?
Free, browser-based converters — no upload, no signup required.
More comparisons
View all format comparisons →