Check the pixel rules as well as the KB limit
Forms that limit the file to 50 KB often also fix the width and height, or a minimum resolution. Set those first in the image resizer, using Fill exactly, trim the edges so the face is not stretched, and then compress here.
Keep the face sharp
Officials look at the eyes, nose and mouth. Light the face evenly from the front, avoid shadows on the background, and do not use filters or beauty modes. These rules are about the photo itself, and no compression setting can fix a blurry or dark original.
JPG is the safe format
Almost every application portal accepts JPG, and it gives the smallest file for photos. Avoid WebP and HEIC for forms even if your phone saves them by default. Leave Save as on Same format for JPG photos, or choose JPG for anything else.
When the portal still says the file is too big
Some portals add their own limits on dimensions or use a strict byte count. Lower the target to 45 KB, or pick a smaller Longest side such as 600 px, and try again. If a form also has a minimum, such as “between 20 KB and 50 KB”, check the result is above it, or use increase size in KB.