<picture>
<source srcset="image.webp" type="image/webp" />
<img src="image.jpg">
</picture>
and you only need to bother with this on images it might matter (e.g. key large multi MB photos in a blog post or something not all of the 20x20 logo icons that would be less than 2kb even if uncompressed).