What Are XMP Sidecar Files in Lightroom Classic - and Should You Enable Them?

By David · June 29, 2026 · 7 min read

Quick Answer

Lightroom Classic stores every edit you make in a central catalog file, not inside your photos. XMP sidecar files are small text files placed next to each RAW that replicate those edits in an open, portable format any other app can read. Turning them on is optional - but if your catalog ever gets corrupted, sidecar files are often what lets you recover develop adjustments, keyword tags, and ratings without starting over.

I work directly inside Lightroom's Plugin SDK. Both Face Tagger and Smart Search write their output as Lightroom keyword metadata - and that means I've had to think carefully about where that data actually lives, and what happens to it if the catalog is lost. XMP sidecar files are the answer, but I never see the plugin angle covered in the standard tutorials.

Where do Lightroom Classic edits actually live?

Every develop adjustment, star rating, keyword, and color label you apply in Lightroom Classic lives in the catalog: a single SQLite database file with a .lrcat extension, usually in your Pictures folder alongside a companion .lrcat-wal write-ahead log.

That design is mostly good. Your original RAW files are never touched. You can revert any edit instantly, create virtual copies that branch from the same RAW without duplicating files, and run the whole editing workflow against a fast local database rather than writing into the file system on every change.

The downside is obvious once you think about it: one corrupt catalog and you lose every edit, keyword, and rating you've ever applied. Adobe includes an automatic backup system (Catalog Settings > General), but those backups are only as current as the last scheduled run. If you make 300 edits after Monday's backup and the catalog fails on Wednesday, those 300 edits are gone.

What is an XMP sidecar file?

An XMP sidecar is a small plain-text file - typically 2-8 KB - placed in the same folder as your original RAW, with the same base name and a .xmp extension. If your RAW is IMG_5412.CR3, the sidecar is IMG_5412.xmp.

XMP stands for Extensible Metadata Platform, an Adobe-developed open standard based on XML. Because the format is open, any application that reads XMP can understand your Lightroom develop settings, ratings, and keywords - not just Lightroom. Capture One, Photo Mechanic, Darktable, and most digital asset management tools read XMP natively.

For file formats that allow embedded metadata (JPEG, TIFF, PNG, DNG), Lightroom writes XMP directly into the file itself rather than creating a sidecar. Separate .xmp files appear only next to proprietary RAW formats - Canon CR2 and CR3, Nikon NEF and NRW, Sony ARW, Fujifilm RAF, and others - because those formats are closed to third-party writes.

How do you turn on automatic XMP writing in Lightroom Classic?

The setting ships off by default. To enable it: open Lightroom Classic menu (Mac) or Edit menu (Windows), go to Catalog Settings > Metadata tab, then check "Automatically write changes into XMP."

Once on, every change you make - a develop tweak, a new keyword, a star rating, a pick flag - triggers a background write to the sidecar (or into the file for JPEGs and DNGs). Metadata-only changes like keyword additions happen in under a second. Develop adjustment writes are also fast because XMP stores the parameter values, not pixel data.

You can also write XMP on demand without enabling auto-write globally: select photos in Grid view and press Cmd+S (Mac) or Ctrl+S (Windows), or use Metadata > Save Metadata to Files. Useful as a manual checkpoint after a heavy editing session.

What gets written to XMP - and what stays catalog-only?

This distinction matters more than most tutorials explain. Not everything in your catalog transfers to XMP:

Lightroom data Written to XMP? Notes
Develop adjustments Yes All sliders, tone curves, HSL, lens corrections, profiles
Star ratings Yes 0-5 stars
Color labels Yes Red, yellow, green, blue, purple
Pick and reject flags Yes Both picked and rejected status
Keywords Yes Full hierarchical keyword paths
Copyright and IPTC fields Yes Caption, creator, rights, GPS coordinates
Virtual copies No Exist only in the catalog - no XMP equivalent
Collection membership No Which albums a photo belongs to stays in the catalog
Smart Collections No Rule definitions live in the catalog, not per-file
Stacks No Stack order and grouping are catalog-only
Edit history states No The full step-by-step history stays in the catalog
Publish status No Published/Modified/New state is catalog-only

The virtual copies row matters most for power users. If you rely on virtual copies for alternate crops or treatments of the same RAW, those alternates have no XMP representation. Losing your catalog loses them regardless of whether auto-write is on.

Why XMP matters if you use Face Tagger or Smart Search

This is the connection I never see in generic XMP tutorials, and it's the main reason I wanted to write this post.

Both Face Tagger and Smart Search write their results as Lightroom keyword tags. Face Tagger applies person-name keywords under a People > hierarchy based on face recognition. Smart Search writes content-descriptive keywords - "mountain," "golden hour," "portrait" - based on what it finds in the image.

Those keyword tags live in the Lightroom catalog by default. If you run Face Tagger across 4,000 photos and confirm identifications for 900 faces, that work sits in your .lrcat file until something writes it elsewhere. With auto-write-to-XMP off, a catalog corruption means losing all of it.

With auto-write-to-XMP on, every keyword Face Tagger or Smart Search writes gets flushed to the sidecar within seconds. If your catalog becomes unrecoverable, you can create a new catalog, point it at your photo folders, and let Lightroom read the XMP sidecars on import. Every person tag and content keyword comes back automatically because it was already in the .xmp file next to the RAW.

Face Tagger and Smart Search write keyword tags that are only as durable as your catalog - unless XMP sidecar writes are on.

Should you turn on automatic XMP writing?

My answer: yes, for most Lightroom Classic photographers.

Turn it on if your original RAW files live on a drive that stays connected (an internal drive, external drive, or NAS), and you're not in a workflow where extra files alongside your RAWs cause problems. The write overhead is negligible on modern hardware - Lightroom batches XMP writes in a background thread and the files are tiny.

One caveat worth knowing before you flip the switch: if you sync your photo folders to cloud storage that charges by file count rather than total storage size, you'll now have twice as many files. A 50,000-photo library generates 50,000 additional .xmp files. Most cloud services (Backblaze B2, S3, Dropbox) price on storage volume, not file count, so this is usually not an issue - but check your plan first.

If you have any interest in using Face Tagger or Smart Search, the case is even stronger. AI-generated keyword tags represent real time and real decisions. Writing them to XMP costs nothing and gives you a per-file backup of the output that survives catalog loss, machine migration, or a clean reinstall of Lightroom.

The alternative - keeping auto-write off and relying entirely on Lightroom's catalog backup schedule - works fine until it doesn't. A weekly backup on Tuesday means Monday's work is always at risk. XMP sidecars are real-time protection.

Frequently asked questions

Do XMP sidecar files work for JPEG and TIFF, or only for RAW?

JPEGs, TIFFs, and DNGs don't use separate sidecar files. When you enable auto-write, Lightroom writes metadata directly into those file formats using the embedded XMP block inside the file itself. Separate .xmp sidecars only appear next to proprietary RAW formats (CR2, CR3, NEF, ARW, ORF, RAF, etc.) where the file format doesn't allow third-party metadata writes.

If my Lightroom catalog gets corrupted, can XMP files restore everything?

Develop adjustments, keywords, ratings, color labels, and IPTC fields - yes. Virtual copies, collection membership, Smart Collections, stacks, and publish history - no. XMP preserves the per-file metadata layer but not the organizational layer that lives only in the catalog. Regular catalog backups (at least weekly) are still essential alongside XMP.

Does enabling automatic XMP writing slow Lightroom down?

Not meaningfully. Lightroom queues XMP writes in a background thread. For metadata-only changes (keywords, ratings, flags) the write takes milliseconds. For develop adjustments, the XMP file is still tiny because it serializes the adjustment parameters rather than pixel data. On spinning hard drives you may notice a brief disk activity spike; on SSD the writes are imperceptible.

Can I write XMP for specific photos without turning on auto-write globally?

Yes. Select photos in Grid view and press Cmd+S (Mac) or Ctrl+S (Windows), or go to Metadata > Save Metadata to Files. This triggers a manual save to XMP for just those selected photos. It's useful as a point-in-time checkpoint after a keywording session without committing to continuous background writes.

Do XMP sidecar files capture Lightroom's develop history states?

No. The full edit history - every slider you touched at every step - stays in the catalog. What XMP captures is the current state of all develop settings, equivalent to what a Develop preset stores. Named Snapshots saved in Lightroom's History panel are also catalog-only and do not transfer to XMP.

Face Tagger recognizes faces and writes person-name keywords. Smart Search lets you find photos by description and tag them. Both plug into the Lightroom keyword layer that XMP protects.

David. Creator of Lightroom Tools. Building Lightroom Classic plugins to simplify photographers' workflows. Spend less time managing photos, more time shooting them.

Lightroom tips in your inbox

Practical Lightroom Classic workflows and plugin updates, about once a month. No spam, unsubscribe anytime.