Skip to content

WP image resizing can result in a larger file size than the original. #264

@peterwilsoncc

Description

@peterwilsoncc

Bug Description

Trac ticket: https://core.trac.wordpress.org/ticket/50866
Related https://core.trac.wordpress.org/ticket/36477

When an image is uploaded, WP can create a crop that has a larger filesize than the original. WP will then default to using the crop when the media is inserted, thus increasing the page size.

Steps to reproduce

  1. Set a WP image size to 512x512
  2. Create a 512x512 PNG with maximum compression
  3. Upload the image to the media library
  4. compare image.png and image-512x512.png, the latter is likely to have a larger file size.

Additional Context

Originally reported by https://profiles.wordpress.org/hvar/, the above is a summary and further information appears on the trac ticket linked above.

At the time of writing this is on the 6.0 milestone.

Metadata

Metadata

Assignees

Labels

[Type] EnhancementA suggestion for improvement of an existing feature

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions