NaturalCam

NaturalCam/Tutorials/RAW vs JPEG

RAW vs JPEG on iPhone, and why you probably want both

Apple has muddied "RAW" into three different things on iPhone, and photographers argue about it like it's one setting. It isn't. What a Bayer RAW frame actually gives you, why JPEG and HEIF haven't gone anywhere, and why that choice lives on NaturalCam's modes instead of a menu.

Tutorial 02 · RAW

11 August 2026

About 8 minutes

iOS 18 · AVFoundation

Every "RAW vs JPEG" article ends up in the same place: RAW is bigger and better, JPEG is smaller and worse, shoot RAW if you can afford the space. That's not wrong, exactly, but it skips the two questions that actually matter on an iPhone — what "RAW" is even claiming to be, since Apple sells three different answers to that, and which of your shots the headroom is for, since it is almost never all of them.

What "RAW" means on a sensor

A camera sensor doesn't see colour. Every photosite sits behind exactly one colour filter — red, green, or blue, arranged in the repeating grid a Bayer sensor is named for — so what the sensor actually reads out is a grey mosaic wearing a colour pattern, not a picture. Every photo you have ever looked at off a phone has been through demosaicing: neighbouring photosites blended together so each final pixel gets an R, a G and a B value it never directly measured.

"RAW" is a promise about when that blending — and everything that happens after it — takes place: before you ever see the file, decided once and for good, or after, on your own terms. JPEG and HEIF make every one of those decisions up front: demosaic, white balance, tone-map, sharpen, denoise, compress, discard. A true RAW file does none of it. It is the mosaic, plus the metadata a developer needs to turn it into a picture — which is also why a RAW file straight off the sensor looks flat and slightly wrong if you ever peek at it undeveloped.

Bayer RAW is not Apple ProRAW

This is the part most explainers skip, and it's the reason "just shoot RAW" is not a complete sentence on iPhone. Apple's own Camera app offers Apple ProRAW on Pro models — and Apple ProRAW is already a demosaiced, linear DNG that has been through Smart HDR and Deep Fusion before it's written to disk. It's shaped like a RAW file and it carries real headroom, but the fusion decisions are already baked in. It is a processed photo wearing a RAW container.

Bayer RAW is the other thing: the sensor's mosaic, before any of that. Third-party apps reach it through AVCapturePhotoOutput, and the API is explicit about the difference — this is the guard NaturalCam's capture path checks before it will fire the shutter:

// Bayer RAW, NOT ProRAW: ProRAW is a demosaiced linear DNG that has
// already been through Apple's fusion pipeline.
guard let rawFormat = photoOutput.availableRawPhotoPixelFormatTypes.first(where: {
    AVCapturePhotoOutput.isBayerRAWPixelFormat($0)
}) else {
    completion(.failure(CameraError.bayerRAWUnsupported))
    return
}
A constraint that comes for free

Bayer RAW capture is only legal at videoZoomFactor == 1.0 — the sensor's native focal length, no digital crop pretending to be a zoom. Ask for it at any other zoom and capturePhoto raises an uncatchable exception. It's a hard Apple-side limit, not a NaturalCam opinion, though it happens to agree with one: one locked physical lens, nothing invented between it and the file.

What RAW actually buys you

Three things, and they're all versions of the same idea: nothing is thrown away yet.

  • Bit depth. iPhone sensors read out somewhere around 10–12 bits per photosite. JPEG flattens that to 8 bits per channel and bakes a tone curve on top of the cut. More bits before compression means more room to pull shadows up or bring highlights down before you see banding.
  • No destructive decisions. Sharpening, noise reduction and local tone-mapping are applied exactly once in a JPEG or HEIF, at capture, and there is no undoing them. RAW defers every one of those calls to whoever develops the file — which is the whole reason NaturalCam's own developer exists:
/// Develops a Bayer RAW DNG into a "natural" HEIF: demosaic + colorimetric
/// rendering only. No sharpening, no noise reduction, no local tone mapping —
/// grain and soft detail are preserved on purpose, which is the whole point.
enum NaturalDeveloper { ... }
  • It's re-developable. Because nothing was discarded the first time, the same DNG can be developed again — a different exposure push, a different white balance, a different look — as many times as you want. NaturalCam's re-develop flow can even replace the original in Photos in place, and because Photos stores that as an adjustment rather than an overwrite, the untouched capture stays one tap away behind Revert.

What it costs

None of the above is free, and the honest RAW-vs-JPEG conversation has to include the bill:

  • Size. A Bayer RAW off a 12 MP sensor lands around 24–28 MB. The developed HEIF next to it is a few megabytes. Roughly five to six RAWs for the storage cost of one JPEG.
  • Time. Demosaicing and colour science aren't instant — turning a DNG into a picture takes real CPU and GPU work, which is exactly why capture and develop are two separate steps rather than one: the shutter is free the moment the sensor has handed over the frame, and the develop happens after, off to the side, whether it takes a tenth of a second or two.
  • Not instantly shareable. A RAW file isn't something you can drop into a text thread and have it look right on the other end without an app that knows how to develop it first.

Why JPEG and HEIF haven't gone anywhere

Most of what a phone camera captures isn't a photograph in the deliberate sense — it's a receipt, a parking spot, a screenshot of a screenshot, a "does this look right" sent to one person who will look at it for two seconds. None of that benefits from 12-bit headroom it will never be pushed to use. And Apple's own in-camera processing — Smart HDR, Deep Fusion — is frequently good on its own merits. Switching it off is a trade, not a strict upgrade: you're buying control with time and storage, and control is only worth buying when you intend to spend it.

How NaturalCam applies it

Most shots don't need the headroom, and the ones that do are rarely a surprise — a deliberate setup, a light worth coming back to, a frame you're already composing carefully. Rather than a global RAW toggle buried in Settings, which asks you to make that call one shot at a time, under time pressure, exactly when you're least likely to get it right, the decision lives on the mode itself:

/// Whether to keep the Bayer RAW alongside the developed photo.
///
/// Every capture is developed from RAW regardless — that is the whole
/// pipeline — but the DNG is around 24 MB, and a mode for casual shooting
/// has no reason to keep it. The cost of turning it off is that those
/// shots can never be re-developed, since there is nothing to go back to.
var savesRAW: Bool

The default is true, and it stays quiet about it — the capture badge only ever says something when RAW is off, because keeping it is what the app is for and the exception is the thing worth a flag. A mode built for a deliberate setup — low light, golden hour, a lens you had to walk somewhere to use — keeps savesRAW at its default. A mode built for grabbing something quick turns it off once, when the mode is set up, and every capture through it inherits that decision without asking again.

The thinking happens once, per mode, instead of every time the shutter is about to fire.

The numbers, side by side

Bayer RAW DNG against a developed HEIF, off the same 12 MP frame.
Bayer RAW (DNG)JPEG / HEIF
File size~24–28 MB~5 MB
Bit depth10–12 bit / channel8 bit / channel
Processing baked inNone — demosaic only, on your termsSmart HDR, sharpening, noise reduction
Re-developableYes — same file, new look, exposure, WBNo — the decisions are final
Ready to shareAfter a develop stepImmediately
Right forShots you'll come back toShots you're sending once
RAW is not a quality setting

It's a decision to do the processing yourself, later, when there's a reason to. That reason doesn't show up on most shots — which is exactly why NaturalCam develops every RAW into a natural HEIF the moment it's captured — demosaic and colour rendering only, no Smart HDR, no Deep Fusion, no sharpening — so an unprocessed picture never depends on keeping the DNG. The RAW is there for the shots you might want to redevelop, not a tax on the ones you won't.