Key takeaways
- WordPress added WebP support in version 5.8; server image-library support is still required for processing uploads.
- Convert a copy of the original and compare it visually before importing it into the media library.
- Replacing a file on disk is different from updating attachment records and references in posts.
- Check the actual image requested by the browser, including thumbnail sizes and cache behavior.
Check WordPress and Hosting Support First
The WordPress WebP announcement documents support beginning with WordPress 5.8. That does not mean every hosting account can create WebP thumbnails. WordPress delegates image operations to a server library such as GD or Imagick, and its installed build must support the format. Use a currently supported WordPress release, check Site Health media information where available, and test a small nonconfidential WebP before converting a large library. A successful upload with missing thumbnails is a processing problem, not evidence that the source file needs a new extension.
Separate three questions: can the browser display the file, can WordPress accept the upload, and can the server generate intermediate sizes? Each can have a different answer. Security plugins, multisite policies, and host restrictions can also reject an otherwise valid image. Ask the host about WebP decoding and encoding if thumbnail generation fails. Do not bypass upload checks or modify executable-file permissions to make an image pass; fix the supported media configuration instead. Keep the original JPEG or PNG available while investigating.
Prepare a WebP From the Right Source
Start with the largest clean source you actually own, not a thumbnail downloaded from your current homepage. Use the JPG to WebP converter for photographic sources or PNG to WebP for PNG artwork. If the image is oversized, use the converter's maximum-dimension control to resize during the same export. A photograph displayed at 800 CSS pixels might justify a 1600-pixel source for a high-density display, but it does not automatically require the camera's entire 6000-pixel width. Plan the actual layout before choosing dimensions.
Treat quality as an experiment rather than a guaranteed percentage saving. Export a candidate around the middle-to-high quality range, then compare faces, labels, gradients, and edges with the original at normal viewing size and at 100% zoom. A smaller output is useful only if it remains suitable for the job. WebP can preserve transparency in lossy mode, but JPEG cannot. Inspect transparent logos against both light and dark backgrounds. The lossless versus lossy guide explains why a maximum quality slider is not the same as an explicit lossless encoder.
Upload New Media With Descriptive Context
For a new article, upload the prepared file through the media library and insert it using the normal image block. Use a short, descriptive filename before upload, such as cedar-desk-drawer-detail.webp. Write alternative text for what the image contributes in this article, not a list of search terms. A decorative texture can have empty alt text; a detail photograph should describe the detail that matters. Captions are optional visible editorial context and do not replace alt text. The image alternative-text guide covers functional and decorative cases.
Choose an appropriate image size in the block rather than always selecting Full Size. WordPress often generates several intermediate sizes and responsive markup, but the theme and block configuration decide what reaches the page. Preview a narrow mobile layout and a wide desktop layout. If a tightly cropped thumbnail cuts off the product, adjust the crop or use a different source composition. A file can be optimized perfectly and still be the wrong picture for the available shape; format conversion cannot solve that editorial choice.
Migrate Existing Images Without Losing References
An existing attachment may be referenced in posts, page-builder data, CSS backgrounds, social preview metadata, and external websites. Renaming photo.jpg to photo.webp on the server changes none of those references and does not convert the underlying bytes. Replacing media safely requires a backup, a staging test, and a migration method that understands attachment records and generated sizes. Decide whether old URLs will remain available, redirect, or continue to serve originals. Do not remove the original files until you have checked where they are used and how rollback will work.
For a small site, updating a few important pages manually can be easier to verify than installing a site-wide rewriting system. For a large library, compare maintained optimization solutions with your host's delivery features and test one representative page first. Avoid stacking multiple plugins that all rewrite image URLs or negotiate formats: their caches can disagree about which file is current. Record the original URL, attachment identifier, replacement URL, and affected pages. The batch conversion workflow helps prepare files, but conversion alone does not migrate a WordPress database.
Verify the Delivered File, Not Just the Media Library
Open the published page with developer tools and inspect the image request. Confirm the response succeeds, the content type matches the intended format, and the downloaded dimensions are reasonable for the rendered slot. With responsive images, the visible source attribute is not always the file actually selected; inspect currentSrc or the Network panel. Repeat with cache disabled and a mobile viewport. The responsive images guide explains how candidates are selected and why a browser can legitimately choose a larger variant on a high-density screen.
After replacing media, clear only the relevant application or CDN caches through their supported controls and then check again in a fresh session. Test the homepage, an archive card, the article, and any product zoom viewer using the attachment. Check broken images, distorted proportions, missing alt text, and unexpected layout movement. Performance should be measured on the page, not inferred from a file-size screenshot. A smaller hero may improve loading, but slow server response, delayed discovery, and blocking resources can still dominate the result. Keep an example before-and-after record so later changes remain traceable.
Frequently asked questions
The questions people ask most about webp in wordpress: upload, replace and verify, answered directly.