Key Takeaways
Keep the original, confirm it opens, and explicitly re-encode a copy as JPEG. Its extension should agree with the output, but the name alone proves nothing. The opaque 80×60 teaching image below isolates encoding from size, transparency and platform approval.
- Renaming a file does not change its image encoding; distinguish its extension from its actual format.Read the supporting section: Separate the three meanings of “type”
- Keep the original, explicitly export as JPEG, then open and inspect the downloaded copy.Read the supporting section: Export once and inspect the downloaded copy
- If a real JPEG is rejected, check size, dimensions and platform conditions rather than repeatedly renaming it.Read the supporting section: If a real JPEG still fails, isolate the next condition
In this article
Separate the three meanings of “type”
A filename is a label; the content contains the information a decoder needs. File.type or Blob.type is another observation, not a reliable inspection of those bytes. MDN’s Blob.type documentation explains that browsers may infer the reported type from the extension and warns against using it as the sole validation.
Consequently, a .jpg name, an image/jpeg label and genuine JPEG content are different claims. A tolerant viewer opening a wrongly named file does not establish that an upload service will accept it. Preserve the original rather than repeatedly overwriting it.
| Observation | What it tells you | What it cannot establish alone |
|---|---|---|
| Filename ends in .jpg | The current extension | That re-encoding happened |
| File.type is image/jpeg | The media-type label provided | Valid bytes meeting the recipient’s rules |
| Viewer opens the image | That viewer can decode it | Compatibility or approval everywhere |
| New export inspected | A separate output was generated | Guaranteed upload acceptance |
Make a small control image
Create an opaque, non-sensitive 80×60 PNG, such as simple colored blocks. Save source.png, then duplicate it as renamed.jpg without opening and resaving it in an editor. The copies should have identical byte lengths and content hashes; the dimensions remain 80×60.
This is an original teaching control, not a customer file or a documented platform rejection. A PNG commonly begins 89 50 4E 47 0D 0A 1A 0A, while JPEG normally starts FF D8. Signatures help spot obvious mismatches; they do not replace decoding, security checks or full validation. You need not install a hex editor to follow the practical route. The WHATWG image-type pattern table lists these signatures.
Two routes, different expected results
source.png → duplicate as renamed.jpg Bytes unchanged: still PNG content.
source.png → choose JPEG in an editor → download converted.jpg New JPEG content; inspect dimensions separately.
Export once and inspect the downloaded copy
Add the original PNG to image format conversion and explicitly select JPEG. The page may retain previous settings; seeing a preview does not confirm the selected format. Check crop, resize and background options, keeping this example at 80×60 with an opaque background, then apply settings and generate the preview.
Download the actual result under a new name. Reopen it and verify that it decodes, has an appropriate extension, remains 80×60 and retains the intended blocks without clipping. If you receive a ZIP, extract and inspect the image inside rather than renaming the archive for upload.
Use the format-selection guide to decide whether JPEG is appropriate. For transparency, choose a background deliberately; the PNG-to-JPEG background check handles that separate issue. This control is opaque so it does not confound the diagnosis.
If a real JPEG still fails, isolate the next condition
Read the recipient’s current requirements for format, bytes, minimum dimensions, aspect ratio and account access. Retry with the downloaded control. If that succeeds while the original does not, compare their dimensions and sizes. One accepted control does not imply acceptance of every JPEG.
Change quality or dimensions only after identifying a relevant limit. Correct the canvas for an aspect-ratio error; retain the actual message for an account or network problem. Changing format, size, account and browser simultaneously makes the cause harder to identify.
MDN’s format reference documents common extensions and media types, not the acceptance rules of a recruitment site, seller portal or school. KitNelo cannot approve an upload on those services.
Inspect the delivered file
- Retain the PNG master and save conversion separately.
- Confirm new encoding, successful decoding and a matching filename.
- Check dimensions, ratio, background and visual content independently.
- Record upload success only after the actual recipient accepts it; conversion is not approval.
Further reading & sources
Put the guide into practice
Open the relevant tool, preview the result and check your exported file.


