Jump to main content

Nicolas Hoizey

  • articles
  • billets
  • links
  • notes
  • talks
  • archives
  • about

Note from 15 March 2022

  • Nicolas Hoizey
  • 15 March 2022
  • Cloudflare, Fastly, HTTP, WebPerf
  • 3 reactions

TIL: #Cloudflare doesn't support the Vary HTTP header, which means the origin server can't do any content negotiation, for example send WebP or AVIF for a JPEG request…

https://developers.cloudflare.com/cache/about/cache-control/#other

#Fastly supports it, just saying… 😅

3 reactions

1 like

  1. Julien LEROY avatar

2 replies

  1. Nicolas Hoizey avatar Nicolas Hoizey
    It is indeed because Cloudflare doesn't support the Vary header to have multiple cache items for the same URL… 😭
    • 15 March 2022, 16:23
    • Source
  2. Nicolas Hoizey avatar Nicolas Hoizey
    It looks like @Cloudflare supports `Vary` for images after all:
    https://blog.cloudflare.com/vary-for-images-serve-the-correct-images-to-the-correct-browsers/(The docs should be updated IMHO)But only for Pro, Business, and Enterprise Customers… 😞
    Vary for Images: Serve the Correct Images to the Correct Browsers
    • 15 March 2022, 16:28
    • Source
  • Older: Note from 15 March 2022
  • Newer: Note from 1 April 2022

Related contents with similar topics

  1. screenshot of Introducing Speed Brain: helping web pages load 45% faster

    Cloudflare avatar Cloudflare , Alex Krivit and Suleman Ahmad

    Introducing Speed Brain: helping web pages load 45% faster

    • Nicolas Hoizey
    • 25 September 2024
    • Cloudflare, WebPerf, Speculation Rules
    • 1 reaction

    With the initial release of Speed Brain, we have designed a solution with important side effect prevention guardrails that completely removes the…

  2. Note from 20 June 2023

    • Nicolas Hoizey
    • 20 June 2023
    • Cloudflare, WebPerf
    • 4 reactions

    Cloudflare in “Faster website, more customers: Cloudflare Observatory can help your business grow”:

    The generated report provides an overall performance score ranging from 1 (least performant) to 99 (most performant)

    First try on my photography site: 100 🤷‍♂️😅

    Screenshot of Cloudflare Observatory showing a 100 score

    Joke aside, new tools to audit performance are always welcome!

  3. Note from 14 April 2023

    • Nicolas Hoizey
    • 14 April 2023
    • Cloudflare, Netlify, TTFB, WebPerf
    • 7 reactions

    I still don't understand why using Cloudflare in front of Netlify allows for a much better and stable Time To First Byte (TTFB) than Cloudflare Pages or Netlify alone… 🤷‍♂️

    SpeedCurve graph with Time To First Byte for the 3 hosting solutions

    TTFB for static sites should always be very low.

  4. screenshot of Caching Header Best Practices

    Simon Hearne

    Caching Header Best Practices

    • Nicolas Hoizey
    • 14 October 2022
    • WebPerf, HTTP
    • 4 reactions

    Client-side caching is a key technique to improving front-end speed and user experience. Whilst it may appear complex and risky, investing the time…

  5. Note from 29 July 2022

    • Nicolas Hoizey
    • 29 July 2022
    • 404, Cloudflare, HTTP
    • 1 reaction

    Some tools transform URLs into links, but if the URL was inside parentheses, the link href sometimes contains the closing ), so the user gets a 404 error… 🤦‍♂️

    Fix this on #Cloudflare Pages with a _redirect file:

    /*) /:splat 301
    

If you want to share an error or suggest an enhancement of this content, please edit the source on GitHub.

© Nicolas Hoizey

Built with Eleventy