WordPress’ Performance Team has published a feature proposal that would enable WebP images by default in the next update to WordPress, expanding core support for the modern image format.
In July, 2021, WordPress 5.8 introduced WebP support, which allows its users to upload and use WebP images in their content. If the proposal is eventually approved, version 6.0 will generate WebP images by default for new JPEG uploads and will use these WebP images by default for website content going forward.
“WebP was developed as a modern image format that provides superior compression on the web,” WordPress core contributor Adam Silverstein said in the feature proposal. “Images are often some of the largest resources used by websites, and using WebP creates websites that are lighter and faster. Compared to JPEG images, WebP images generated by WordPress are almost always smaller, with a ~30% file size reduction on average (with the same visual quality).”
With WebP now being enabled by default, WordPress users would not experience any changes to their usual image upload workflow. WordPress would automatically convert all JPEG uploads to WebP in the background and use them on the website for you.
According to Can I Use, the WebP image format is supported by 94.25% of web browsers to date. A very small number of browsers, such as Internet Explorer 11 or Safari on MacOS < v11 Big Sur, still do not support WebP.
The proposed feature would ship with two filters to control or disable WebP uploads, and a user-friendly plugin would be created to do the same thing.
Despite the significant performance benefits this new format has, support for the feature proposal is not unopposed. Several contributors participating in the discussion expressed concerns about email clients and social media platforms not supporting WebP at this point.
“I feel like WebP is not yet ready to become a ‘hardcoded default’ in the post_content due to all the reasons mentioned in the previous comments,” Kaspars Dambis said. “Many web clients (which are not just browsers) don’t support WebP formats — RSS clients, email clients, smart TVs, ebook readers, open graph parsers, desktop image viewers, etc. These are all important users of the web.”
Silverstein then answered these concerns that were expressed, confirming that WordPress will continue generating the JPEG image sub sizes as it always has.
“One important note about what this feature doesn’t change: JPEG sub sizes are still generated and stored in the same meta fields,” he said. “For that reason, consumers of RSS feeds or REST media endpoints or OG tags for example will continue to use the JPEG sub sized versions.”
The Performance Team contributors are targeting WordPress 6.0 for enabling WebP by default and are seeking approval from the maintainers of the image component. Anyone is welcome to test the feature by installing the Performance Lab plugin on their own sites or testing platforms with the “WebP Uploads” module activated. Testers are encouraged to leave feedback on the Trac ticket or Pull Request so the team working on this feature can make the necessary changes.