# Campaigns and ads are impacting your Core Web Vitals via TTFB

- 2021-10-22
- 3 min read

Tags:

- [core web vitals](/md/blog/tag/core-web-vitals/)
- [cloudflare](/md/blog/tag/cloudflare/)
- [caching](/md/blog/tag/caching/)

![campaigns-and-ads-are-impacting-your-core-web-vitals-via-ttfb.png](/file/upload/img/blog/campaigns-and-ads-are-impacting-your-core-web-vitals-via-ttfb.png?v=d3a9df7eb438)

Let's take one step back: when a visitor visits a page on your website or webshop, a request is sent to the origin server. This is a physical server with your dynamic files (Node.js, PHP, et cetera). These files are then responsible for generating HTML, which basically is server side rendering.. on the fly. TTFB is a metric telling us when the first bytes of HTML was received by the browser.

## Server side caching to reduce TTFB

But you, or one of your colleagues were smart and implemented some sort of server side caching. This reduces the amount of work needed to be done on the server to come back with HTML whenever it is requested. The server, or your very own platform knows which page to return based on its unique URL.

As a result, TTFB will improve.While you could still [hack your LCP metric](/md/blog/hack-pagespeed-lcp-metric-by-enlarging-hero-image/) without improving TTFB, metrics such as FCP and LCP will always benefit even more when improving TTFB, resulting in an additional boost of your [Core Web Vitals](/md/google-core-web-vitals-pagespeed/).

## Query strings impacting TTFB

Here's the catch though: although contents could just be the same per url, each url might be requested with additional and more importantly different query strings. For example:

- home.html?gclid=abc
- home.html?utm\_campaign=xyz

And this often is where issues arise. A specific advertisement or campaign won't result in different contents within the requested page, but the caching mechanism doesn't know. It just sees this as a new unique URL, hence putting the server and your dynamic files at work, creating HTML on the fly once again.

This is adding costly time to the TTFB metric, impacting user engagement and conversion via those other metrics (FCP, LCP).

## Ignore (common) query string parameters

Quick win: ignore query string parameters which won't be impacting contents. While pagination, search or filtering parameters in a query string will result in different HTML, there are a bunch of parameters which doesn't have nor need this behaviour.

So, as part of your caching strategy, be sure to ignore the following parameters:

- **UTM**  
  utm\_source  
  utm\_medium  
  utm\_campaign  
  utm\_id  
  utm\_term
- **Facebook**  
  fbclid
- **Meta**  
  meta\_placement  
  meta\_site\_source
- **Google Analytics**  
  \_gl
- **[Google Ads](https://support.google.com/google-ads/answer/10417364)**  
  gclid  
  dclid  
  wbraid  
  gbraid  
  gad\_source
- **Search Ads**  
  gclsrc
- **Microsoft**  
  msclkid
- **Adobe**  
  bid  
  cid
- **Pinterest**  
  epik  
  pp
- **TikTok**  
  ttclid
- **Klaviyo**  
  \_kx
- **Other**  
  [srsltid](https://www.rumvision.com/blog/srsltid-impacting-core-web-vitals-via-ttfb-caching/)  
  channable  
  awc (awin.com)  
  dm\_i (dot digital email)

An even [longer list can be found here](https://maxchadwick.xyz/tracking-query-params-registry/).

## When using Cloudflare

When using Cloudflare, Cloudflare will make it easy for you to determine if you're having caching issues. Check the response headers of your webpage and look for the cf-cache-status header. [It should read HIT](https://community.cloudflare.com/t/cf-cache-status-dynamic-why/135578). If not, Cloudflare did not return a cached page for whatever reason. One of those reasons could be query string parameters that you didn't exclude yet. Read how to [properly setting up Cloudflare for faster TTFB](/md/blog/properly-setting-up-cloudflare-caching-for-faster-ttfb/).

So, be sure to add the above parameters to your ignore list as it's a no-brainer which will obviously improve not just metrics, but also:

- (early) user engagement;
- bounce and conversion;
- SEO via Core Web Vitals;
- And maybe even ad spent/CPC, a win/win!

Know of more common parameters? [Let me know](/md/hire-web-consultant/) and I'll add them.

## Read next

- ![cloudflare-new-york.jpg](/file/upload/img/blog/cloudflare-new-york.jpg?v=d9c673317666)
  ### [Web performance company without passing Core Web Vitals](/md/blog/web-performance-company-without-core-web-vitals/)
  9 February 2021
- ![rocket-loader-website-launch.jpg](/file/upload/img/blog/rocket-loader-website-launch.jpg)
  ### [Cloudflare Rocket Loader and Core Web Vitals](/md/blog/rocket-loader-and-core-web-vitals/)
  1 October 2020
- ![cloudflare-new-york.jpg](/file/upload/img/blog/cloudflare-new-york.jpg?v=d9c673317666)
  ### [Properly setting up Cloudflare caching for faster TTFB](/md/blog/properly-setting-up-cloudflare-caching-for-faster-ttfb/)
  2 November 2021
