How to setup WebP with CDN & Cloudflare?

NoteUsing rewrite rules to display WebP images is not possible when either CDN or Cloudflare are active on your site. If you decide to display WebP format on your site by using <picture> tags, a CDN URL field will show up in the settings page.

Cloudflare
If you use Cloudflare Free or Pro ($20 per month) plan, there is no need to add anything in CDN URL field. This is because Cloudflare (all plans below Business) does not offer custom CNAME Setup, which means your images’ paths will stay the same as before setting it up.

Standard CDN services
Using a “classic” CDN service (one that offers you custom CNAME/CDN URL) requires use of a custom URL related to their servers. In this case, it is important to add this CNAME URL (given by the CDN provider) in the CDN URL field.

Some “classic” CDN providers: