fileformer
search⌘KtranslateENexpand_moreupload_fileConvert
Converters8 file families · 44 direct conversions
What changes in a conversionarrow_forward
platform guides / wordpress

How to Optimize Images for WordPress

You upload one photo.
WordPress writes several.

On upload, WordPress core makes a copy at every registered size it can fit, and since 5.3 it scales anything over 2560 px down to a "-scaled" copy that pages use instead of your original. This page runs the same rules (wp_get_registered_image_subsizes, big_image_size_threshold, JPEG quality 82) in your browser and writes the real files.

4032×3024 camera JPEG1600×900 banner
wp-content/uploads/2026/10/resizing…
SRCSET

Which of those files does a visitor download?

When you insert the image, WordPress writes a srcset listing every copy with the same shape (the square thumbnail is left out) up to 2048 px, plus a sizes attribute. The browser does the choosing. Move the sliders to see what a phone, a laptop or a 4K screen fetches.

Inserted asMediumLargeFull size
Pixel density1×1.5×2×3×
The image fills 1024 CSS px; at 2× that needs 2048 device pixels (red mark). The browser takes the smallest file at least that wide: IMG_4512-2048x1536.jpg, 57 KB. Copies wider than 2048 px are never listed, so the 2560 px file is only used by "Full size" links.
…
Your browser, right nowLoading the generated files into a real img element…

Image formats in WordPress core

formatsincewhat core doesthis browser
JPEG1.0sub-sizes at quality 82; EXIF orientation applied on upload since 5.3can encode
PNG1.0sub-sizes stay PNG; no lossy compressioncan encode
GIF1.0sub-sizes are single still frames; only the original animatesn/a
WebP5.8uploads and sub-sizes, if the server’s GD or Imagick supports itcan encode
AVIF6.5uploads and sub-sizes, server support permittingdecode only
HEIC6.7converted to JPEG on upload when Imagick can read itn/a
SVGnot in coreblocked by upload_mimes; needs a plugin that sanitises scriptsdecodes in img
Sources: WordPress core wp-includes/media.php (add_image_size defaults, wp_calculate_image_srcset, max_srcset_image_width 2048), wp-admin/includes/image.php (big_image_size_threshold 2560, wp_create_image_subsizes), WP_Image_Editor default quality 82, make.wordpress.org/core release notes for 5.3, 5.8, 6.5 and 6.7. Server support depends on the host's GD or Imagick build; the right column tests your browser's encoder.