Image repair / PNG & JPEG / runs in your browser
Free online tool to fix damaged JPG and PNG photos that will not open. It reads the file byte by byte, tells you exactly what is broken, repairs what can be repaired and recovers what is left of the rest.
Before anything is written, the file gets a verdict. Knowing which of the four you have saves you from chasing a recovery that was never possible.
The structure checks out. If it still will not open, the problem is the program you are opening it with, not the file.
The image data is all there behind a broken container. Rebuild the structure and you get the photo back whole.
The file was cut short. Everything above the break comes back; below it there is nothing to come back.
No usable image data survives. Said plainly, rather than after twenty minutes of a progress bar.
Every segment is listed with its hex offset, its real name and its size. PNG chunks by their actual identifiers, JPEG markers by their technical designation.
| Offset | Block | Size | Note |
|---|---|---|---|
| 0x000000 | SIGNATURE | 8 B | Valid |
| 0x000008 | IHDR | 25 B | 3024 × 4032 · RGBA · 8 bit |
| 0x000021 | tEXt | 64 B | Valid |
| 0x000061 | IDAT | 1.84 MB | Valid |
| 0x1D8A40 | IDAT | 412 KB / 890 KB | Truncated inside block |
| — | IEND | — | Missing |
Each fault is named, explained, and marked with what can be done about it. Repeated faults are grouped with a count instead of flooding the report.
| Fault | Usual cause | Outcome |
|---|---|---|
| Signature altered | FTP transfer in ASCII mode | REPAIRABLE |
| CRC32 mismatch | A flipped byte in storage or transfer | REPAIRABLE |
| IEND missing | Copy or download stopped early | REPAIRABLE |
| Chunk truncated | Write interrupted; declared length exceeds what is present | PARTIAL |
| Foreign bytes in stream | Overwritten sector; realigns to the next valid chunk | PARTIAL |
| No IHDR found | Header destroyed or file is not a PNG | DATA LOST |
| No IDAT present | Container survived, image data did not | DATA LOST |
| Chunk sequence broken | Severe damage with no valid re-entry point | DATA LOST |
| Implausible dimensions | Corrupted header values | DATA LOST |
| Invalid bit depth | Value outside what the format allows | DATA LOST |
| Invalid colour type | Value outside what the format allows | DATA LOST |
| Fault | Usual cause | Outcome |
|---|---|---|
| SOI marker missing | Bytes lost from the head of the file | REPAIRABLE |
| Foreign bytes prepended | Junk written before the image; the exact count is reported | REPAIRABLE |
| EOI marker missing | Transfer or write stopped early | REPAIRABLE |
| Quantisation tables missing | Header damaged — candidate for grafting | PARTIAL |
| Huffman tables missing | Header damaged — candidate for grafting | PARTIAL |
| Frame header missing | SOF segment destroyed | PARTIAL |
| Truncated inside a marker | File ends mid-segment | PARTIAL |
| Inconsistent segment length | Declared length does not match the data | PARTIAL |
| Scan start not found | SOS marker missing | DATA LOST |
| No compressed data after SOS | The image stream itself is gone | DATA LOST |
01 / Native decode
Before anything is repaired, the file goes to the browser's own decoder, which is far more forgiving than the average desktop application. A surprising share of files that "will not open" elsewhere render immediately here, with no repair needed at all.
It costs nothing to try, and it is the reason some sessions end in three seconds.
02 / Structure repair
For PNG: the signature is rewritten, CRC32 checksums are recalculated, the IEND block is restored, truncated chunks are rewritten with their real length. For JPEG: junk bytes are stripped from the front, and the SOI and EOI markers are put back.
The pixels are never touched. On a file whose only fault is a bad checksum, the output is byte-for-byte identical to what the healthy original would have been.
03 / Row recovery
When a PNG's compressed stream stops mid-file, every row that actually made it is decoded and kept, with the recovered percentage stated. All five PNG filters are supported — None, Sub, Up, Average and Paeth — along with 1 to 16 bit depths, every colour type, palettes and indexed transparency.
Rows that never arrived stay empty. They are not filled in, guessed at or generated.
04 / Header grafting
A JPEG's decoding tables depend on the camera model and the quality setting, not on the individual shot. So a healthy photo from the same camera can supply the header a damaged one has lost — which is why the tool asks for a reference file rather than inventing values.
Because a single byte of misalignment makes Huffman decoding impossible, several candidate boundaries are generated for the start of the compressed data and tried one after another until the image decodes. The offset that worked is reported with the result.
05 / Last resort
Cameras embed a small preview in the EXIF block, physically separate from the main image stream. When the main stream is beyond recovery, that thumbnail is often the only readable picture left in the file — small, but frequently enough to identify what the photo was.
It is extracted and offered as a standalone JPEG.
| Format | Support |
|---|---|
| PNG | DIAGNOSE · REPAIR · RECOVER |
| JPEG | DIAGNOSE · REPAIR · RECOVER |
| GIF | IDENTIFIED |
| WEBP | IDENTIFIED |
| BMP | IDENTIFIED |
| TIFF | IDENTIFIED |
| HEIF / HEIC | IDENTIFIED |
| PSD | IDENTIFIED |
| Output | Note |
|---|---|
| Repaired file | With the exact list of what was changed |
| Rebuilt PNG | From decoded pixels, no quality loss |
| Rebuilt JPEG | Involves recompression, stated upfront |
| Grafted file | With the byte offset that worked |
| EXIF thumbnail | Standalone JPEG |
The wrong extension is the single most common reason a file "will not open" — a .jpg that is really a PNG or an HEIC. That is flagged immediately, and renaming the file is usually the whole fix.
Worth reading before you start, because it will save you a disappointment that other tools let you walk into.
Lost parts stay empty. Nothing is generated, guessed at or filled in — because a plausible reconstruction of a photograph is not the photograph, and on a document or a piece of evidence it would be actively harmful.
Unlike PNG, the format carries no way to verify its own contents. The tool can tell you where the stream stops; it cannot tell you whether a single value inside it was altered.
The compressed stream is continuous. Above the break everything comes back, below it nothing does. There is no middle ground and no partial rescue of the tail.
Row-by-row recovery does not apply, because interlaced files do not store their data in row order. Diagnosis and structural repair still work.
40 MB per file, and no row-by-row rebuild beyond 40 megapixels. Past that the browser runs out of memory, and failing cleanly is better than crashing the tab.
This fixes files that are structurally broken. It does not sharpen, denoise, upscale or colour-correct — a blurry photo is not a damaged one.
Drop the damaged file here
JPEG and PNG are analysed byte by byte. Other formats are identified and checked.
Your file stays on your device. Nothing is uploaded, nothing is stored on the server.
· ·
| Offset | Block | Size | Notes |
|---|
A JPEG's decoding tables depend on the camera model and the quality setting, not on the individual shot. If this file's header is destroyed but the compressed data survives, a healthy photo from the same camera can supply the missing header.
Analysis and repair happen in your browser. The file is never sent anywhere.
The tool shows where the file breaks and why, even when there is nothing left to recover.
You get back only what the file actually holds. Lost parts stay blank.
To provide the best experiences, we and our partners use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us and our partners to process personal data such as browsing behavior or unique IDs on this site and show (non-) personalized ads. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Click below to consent to the above or make granular choices. Your choices will be applied to this site only. You can change your settings at any time, including withdrawing your consent, by using the toggles on the Cookie Policy, or by clicking on the manage consent button at the bottom of the screen.