Skip to content
ToolZool
Buy Zooly a coffee

Troubleshooting · 6 min read

Why an upload form keeps rejecting your file

Size caps, dimension caps and format checks look identical from the outside — the error message is usually the same unhelpful sentence. Here is how to tell them apart.

You have compressed the file. It is under the limit. The form still says “Invalid file. Please try again.”

Upload validators typically check several things and report a single generic failure for all of them. That is why this is so frustrating: the message tells you something is wrong but never which thing. There are six common causes, and each has a tell.

1. A dimension limit nobody mentioned

The tell: your file is comfortably under the stated size and still fails, and the form is for an identity photo or a profile picture.

Many forms cap pixel dimensions as well as bytes, and only publish the byte limit. A 50 KB image can still be 4000 pixels wide, and a validator expecting a 600 × 800 headshot will refuse it.

Fix: resize the long edge to something modest — 600 to 1000 pixels — then compress again. This usually also makes the file dramatically smaller, so you get both checks passed at once.

2. The format is not what the extension says

The tell: you renamed a file, or exported from a phone, or the file came out of a messaging app.

Validators check the file’s actual content, not its name. Renaming photo.heic to photo.jpg changes nothing about what is inside it, and the check fails immediately. iPhones in particular produce HEIC by default, which almost no upload form accepts.

Fix: actually convert the file rather than renaming it. On iOS you can set the camera to “Most Compatible” to get JPEG straight from the camera.

3. A minimum size, not just a maximum

The tell: you compressed hard, got well under the limit, and it started failing when it had worked before.

Some forms require a minimum file size or minimum dimensions, on the reasonable theory that a 4 KB image is too degraded to identify anyone. Compress to the limit, not far below it — the whole point of an exact target is that you land just under.

4. The document has more than one page

The tell: you are uploading a PDF where a single page was wanted, or an image where the form expected one scan.

Multi-page PDFs are refused by forms that expect exactly one page. Similarly, some forms reject animated GIFs even though the extension is allowed.

Fix: split the document and upload the page that was asked for.

5. Colour mode, for print and official uploads

The tell: a print service or an official portal, and an error mentioning “colour profile”, “CMYK” or nothing at all.

Most web forms want RGB. A file exported for print may be CMYK, which many validators reject outright, and some browsers cannot even display.

Fix: re-export as RGB. Any tool that re-encodes for the web will produce RGB by default.

6. Encoding inflation on email attachments

The tell: not a web form at all — an email that keeps bouncing with a size error, even though the attachment is under the stated limit.

Email attachments are base64-encoded for transport, which makes them about 33 per cent larger in the message than they are on disk. A 2 MB file arrives as roughly 2.7 MB of message, so a server enforcing 2 MB still refuses it.

Fix: target about 1.4 MB for a nominal 2 MB limit and it will fit with room to spare.

How to diagnose it quickly

Work through this in order — it goes from most to least common:

  1. Check the pixel dimensions, not just the file size. Your operating system’s file inspector shows both.
  2. Check the real format. If the file came from a phone or a messaging app, assume it is not what the extension claims.
  3. Check you are not far below a minimum. Recompress to just under the cap.
  4. Check the page count if it is a document.
  5. Try a different browser. A surprising number of older portals are broken in one browser and fine in another.
  6. Read the accepted-types list literally. If it says JPG, send a JPEG — not a WebP, however much better it would be.

The general lesson

Upload validators are strict, silent about their reasons, and often older than the phone that took your photo. The reliable approach is to give them exactly what they asked for in the plainest possible form: a JPEG, in RGB, at modest dimensions, just under the size cap.

ToolZool’s compress to an exact size tool handles the size and the dimensions together, and strips the metadata that occasionally trips validators up as well.

Tools mentioned here

IMG / 01 Compress image to exact size Name a limit in KB or MB. Get the best-looking file that fits under it. JPG · PNG · WebP · AVIF
PDF / 01 Compress PDF to exact size Bring a PDF under an upload cap while keeping the text readable and selectable. In build

Keep reading

Spotted something wrong? Tell us — we correct guides and update the revision date rather than editing quietly. See our editorial policy.