A smaller file should still be a useful file.
Start with a sharp original image. Resize only as much as the destination needs, keep the aspect ratio when you want to avoid distortion, and inspect the output before uploading it elsewhere. A low-quality source cannot gain genuine detail through resizing.
JPEG works well for photographs. PNG preserves transparency. WebP can be useful when the website receiving your file accepts it. Choose the format your destination requests, rather than assuming the smallest format is always suitable.
These tools do not certify official photo compliance. Dimensions are only one requirement; background, expression, lighting, recency and editing rules can also matter. For a document made from several images, use Images to PDF.