Truncated JPG image for testing (corrupted)

A damaged JPEG: the first half of a valid 800 × 600 image. The header states the full dimensions, but the picture data stops half-way, with no end-of-image marker.

Download

sample-jpg-truncated.jpg

55.2 KB56,556 bytes

Download JPG sample

Direct download. No sign-up and no waiting.

Type
image/jpeg
SHA-256
9aed5e37502f664321ed2a2b8804e337f4a9179ffe8968a2fa36855dccdf4d02
Direct URL
https://sampletestfiles.com/downloads/samples/sample-jpg-truncated.jpg

This file is invalid on purpose. The file ends half-way through its compressed picture data, without the end-of-image (FF D9) marker.

Why test with this file

Tests image pipelines against a partial upload. Browsers draw the top of the picture and fill the rest with grey, while stricter decoders refuse the file, so different parts of one system can disagree about it.

DamageTruncated to 50% of its length
Dimensions in header800 × 600 px
Signature (FF D8 FF)Present
End-of-image marker (FF D9)Missing
Lenient decodersShow the upper part of the image
Strict decodersReport a truncated or premature end of file

What to check

After your application has processed sample-jpg-truncated.jpg, confirm that:

First bytes of the file

The first 64 bytes of sample-jpg-truncated.jpg as a hex dump: offset, bytes, then the same bytes as text. The JPG signature is FF D8 FF.

00000000  ff d8 ff e0 00 10 4a 46 49 46 00 01 01 00 00 01  |......JFIF......|
00000010  00 01 00 00 ff db 00 43 00 03 02 02 03 02 02 03  |.......C........|
00000020  03 03 03 04 03 03 04 05 08 05 05 04 04 05 0a 07  |................|
00000030  07 06 08 0c 0a 0c 0c 0b 0a 0b 0b 0d 0e 12 10 0d  |................|

Preview

No preview is offered, because this file is damaged on purpose. Download it and give it to the software you are testing.

Technical details

File namesample-jpg-truncated.jpg
FormatJPG (JPEG image)
Extension.jpg
MIME typeimage/jpeg
Size56,556 bytes (55.2 KB)
KindBinary
SignatureFF D8 FF
SHA-2569aed5e37502f664321ed2a2b8804e337f4a9179ffe8968a2fa36855dccdf4d02
Created2026-10-10
ValidationDeliberately invalid. Independent parsers were confirmed to reject or flag the file when it was generated
PreviewNot offered for deliberately damaged files
SourceGenerated for this site; not copied from elsewhere
LicenceFree to use, modify and redistribute (terms)
CategoryImages

Damaged on purpose, and otherwise harmless: the file holds the same generated content as the valid samples. As with any download, scan the file with your own security tools before opening it. How files are made and checked

Download from the command line and verify

Fetch the file with curl, then compare its checksum with the SHA-256 value above.

curl -o sample-jpg-truncated.jpg 'https://sampletestfiles.com/downloads/samples/sample-jpg-truncated.jpg'
sha256sum sample-jpg-truncated.jpg     # Linux
shasum -a 256 sample-jpg-truncated.jpg # macOS

On Windows, run Get-FileHash sample-jpg-truncated.jpg -Algorithm SHA256 in PowerShell. A matching value proves that the download is complete and unaltered.

About JPG

Lossy compressed photographs. The format most image uploads arrive in.

JPG format reference

Where it fits

Related files

All curated sample files