Skip to content

Early-bird lifetime licence: $199 once, for the first 200 buyers only. See the offer

Stop making extra image sizes

WordPress stops making the 768px, 1536px and 2048px copies of every image you upload. Saves disk space; your theme’s own sizes are still made.

  • Type PHP
  • Runs Everywhere (runs as WordPress loads)
  • Category Media
  • Tested with WordPress 7.1
PHP
<?php

add_filter(
	'intermediate_image_sizes_advanced',
	static function ( $sizes ) {
		unset( $sizes['medium_large'], $sizes['1536x1536'], $sizes['2048x2048'] );
		return $sizes;
	}
);

Good to know

Only affects new uploads. Responsive images use the other sizes, so phones and big screens still get a fitting copy.

In these packs

  • Images and media: Sharper, lighter images, tidier uploads and a more useful media library.

Move your snippets over this afternoon.

Importing changes nothing until you switch over, and your old shortcodes keep working.