Apple Health Export Splitter
Your export.xml too big to open, convert, or feed to AI? Trim it by date range or data type and download a smaller, valid file. Free, private, runs entirely in your browser — nothing is uploaded.
Drop your export.xml here
or choose a file — it never leaves your device
apple_health_export folder, and select export.xml inside. This tool works on the raw XML.
Choose what to keep
How to use it
- On your iPhone, open Health → your profile photo → Export All Health Data. You'll get a
.zip. - Unzip it and find
apple_health_export/export.xml. Drop that file into the box above. - The tool scans it and lists every data type with its record count and the full date range it found.
- Pick a start/end date and/or tick the data types you want to keep. A record is kept only if it matches all active filters.
- Click Build smaller export, then download your trimmed, valid
export.xml.
Why Apple Health exports get so big — and how to shrink them
If you've ever tried to open your Apple Health export.xml and watched your editor freeze, crash, or refuse to load it, you're not imagining it. A multi-year export routinely runs from a few hundred megabytes to several gigabytes. The reason is simple: Apple Health saves every data point your Apple Watch and iPhone ever recorded. Heart rate alone can be logged every few seconds, so a single year produces millions of individual <Record> lines. Add active energy, steps, distance, sleep stages, HRV, and workouts, and the file balloons far beyond what most tools — spreadsheets, text editors, CSV converters, and AI chat windows — can handle in one piece.
What this tool actually does
The Apple Health Export Splitter reads your file in two passes. The first pass scans the whole file in small 8 MB chunks, counting how many records exist for each data type (like HKQuantityTypeIdentifierStepCount or HKQuantityTypeIdentifierHeartRate) and finding the earliest and latest dates present. The second pass filters: it walks the file again and copies through only the records that fall inside your chosen date range and belong to a data type you kept. It then wraps those records with the original file's header and DTD at the top and a closing </HealthData> tag at the bottom, so the output is a genuine, well-formed Apple Health XML file — just much smaller.
Why stream instead of parse the whole thing?
A normal XML parser (like the browser's DOMParser) tries to build the entire document in memory before you can touch it. On a 1 GB health export that means several gigabytes of RAM and, usually, a crashed tab. Instead, this tool reads the file as a stream of bytes, decodes each chunk of text, keeps a small carry-over buffer so records split across a chunk boundary aren't lost, and matches each <Record .../> line with a regular expression. That keeps memory use tiny and flat no matter how large the file is — which is exactly how the Apple Health app itself writes the file: one record per line.
How to read the results
After scanning you'll see a before size and, after building, an after size and the exact record counts kept versus removed. If you only need recent data for an AI summary, try the last 90 days. If you only care about workouts and heart rate, uncheck everything else. If your filter matches zero records, the tool tells you rather than handing you an empty file — widen your date range or select more types. The trimmed file is dramatically easier to open, and it plugs straight into our XML-to-CSV converter or any AI health analysis workflow.
Your data stays yours
Everything here happens locally in your browser. Your export.xml is read with the browser's File API, processed in JavaScript on your own machine, and offered back to you as a download via an in-memory Blob. There is no upload, no server round-trip, and no analytics on your health content. You can even disconnect from the internet after the page loads and it will still work.
Frequently asked questions
Why is my Apple Health export.xml so big?
Apple Health stores every single measurement your devices ever recorded — steps, heart rate every few seconds, workout details, and more. Over a few years this adds up to millions of <Record> lines, so export.xml commonly reaches hundreds of megabytes to several gigabytes. This tool trims it down by keeping only the dates and data types you actually need.
Is my health data uploaded anywhere?
No. The splitter runs 100% in your browser using JavaScript. Your export.xml is read locally with the File API and never sent to any server. Nothing is uploaded, stored, or logged.
Is the smaller file still a valid Apple Health XML?
Yes. It keeps the original XML header and DTD, includes the filtered <Record> and <Workout> elements you chose, and closes with </HealthData>. The result is a well-formed Apple Health-style XML you can open, convert to CSV, or feed to an AI tool.
Can I split by both date range and data type at once?
Yes. Set a start and/or end date and check only the data types you want. A record is kept only if it matches every active filter, so you can keep just heart rate and steps from the last 90 days, for example.
The file is a .zip — what do I do?
Apple exports your data as a .zip. Unzip it first (double-click on Mac, or Extract on Windows), open the apple_health_export folder, and select the export.xml file inside. This tool works on export.xml directly.
How big a file can it handle?
The tool streams the file in 8 MB chunks instead of loading it all at once, so it comfortably handles multi-gigabyte exports without crashing the tab. Very large files simply take longer — the progress bar shows how far along it is.
More free tools
Want deeper analysis?
Turn your trimmed export into trends, scores, and AI-powered insights — on your iPhone or Mac.