Skip to content

Works with your stack

Cookie consent for SiteGround Optimizer

four lists, one rule

← Cookie Rocks for your stack

SiteGround Optimizer can minify, combine and load scripts asynchronously, inline scripts included. On SiteGround hosting it also drives the server’s page cache.

By SiteGround · siteground.com · WordPress.org

Is this your product? Tell us if anything here is out of date. Write to us

SiteGround Optimizer

WordPress plugin

Tested
Tested version
7.8.6
How
Tested automatically around each Cookie Rocks version
Last test
7 November 2026
Latest version
7.8.6 tested
Active installs
1,000,000+

What SiteGround Optimizer adds to your visitors’ browser

No trackers In our test of SiteGround Optimizer 7.8.6 on 7 November 2026, the plugin itself added no tracker and no cookie. What you place in your pages with it, such as a video or a map, still counts.

What matters for consent with SiteGround Optimizer

Minify, combine, async

Each option changes how scripts arrive. The consent script has to stay out of all of them and run first.

Inline scripts combined

SiteGround Optimizer can gather the small scripts written in the page into a file. The consent script at the top of the page has to stay where it is.

The host’s cache

SiteGround keeps pages in a cache on its servers. A banner change reaches visitors once it is purged.

Fonts and lazy loading

SiteGround Optimizer can combine Google Fonts and lazy load images and frames. A frame that loads later still needs consent when it loads.

Cookie Rocks with SiteGround Optimizer

  • Adds the banner’s scripts to its exclusions from delay, combining and minifying.
  • Clears its page cache when you change something visitors can see.

All the features

What our tests found on SiteGround Optimizer

  • Good to know · SiteGround OptimizerSiteGround Optimizer serves one cached page to everyone, whatever the choice

    Its file cache skips only a fixed cookie list (logged-in, carts, comment author) and never stores a response that sets a cookie. A consent cookie is not on that list.

    Read in its code, 16 October 2026, SiteGround Optimizer 7.8.4.

    Full detail

    SiteGround Optimizer's Defer Render-blocking JavaScript adds defer, not async, to enqueued scripts, except handles excluded with sgo_js_async_exclude. Its page rewriting (combination, minification, fonts) and deferral are skipped for logged-in users. Its file cache skips requests carrying a fixed cookie list (sgo_bypass_cookies: logged-in, carts, comment author, wpSGCacheBypass) and never stores a response with Set-Cookie; a consent cookie set in the browser is not on the list, so cached pages stay the same for everyone.

  • Depends on a setting · SiteGround OptimizerSiteGround Optimizer lazy loading can let videos load before the choice

    setting “Lazy load iframes” · by default: off

    With iframe lazy loading on, the video address moves to data-src, which a banner reading only src misses. Cookie Rocks 2.5.0 holds the video and starts it after consent, without a reload.

    Seen in our tests, 16 October 2026, SiteGround Optimizer.

    Full detail

    With lazy loading of iframes on, SiteGround Optimizer moves a video's address from src to data-src. A banner that only reads src lets the video load before the choice. Cookie Rocks 2.5.0 holds it and starts it after consent, without a reload.

  • Good to know · LiteSpeed Cache, W3 Total Cache, SiteGround Optimizer, AutoptimizeCache plugins' JavaScript options keep the Cookie Rocks banner first

    With LiteSpeed Cache, W3 Total Cache, SiteGround Optimizer or Autoptimize combining or delaying scripts, the banner script stays first and untouched, and trackers are held until Accept all.

    Seen in our tests, 15 October 2026, LiteSpeed Cache, W3 Total Cache, SiteGround Optimizer, Autoptimize 7.9.1, 2.10.7, 7.8.4, 3.1.16.

    Full detail

    With JavaScript combined, minified or delayed (LiteSpeed Cache including Guest Mode and Load JS Delayed, W3 Total Cache minify in auto mode, SiteGround Optimizer combine and async, Autoptimize aggregate including inline JS), the Cookie Rocks head script stays first and untouched, its engine stays a separate file, and trackers are held until Accept all. Without a LiteSpeed web server, LiteSpeed Cache sets no cookie.

  • Good to know · SiteGround OptimizerSiteGround Optimizer's script combining keeps the banner and holding working

    setting “Combine JavaScript Files ; Defer render-blocking JavaScript”

    With minify, combine and async loading on, the Cookie Rocks head script stays first, the banner shows and trackers are held until Accept all. SiteGround's dynamic cache was not tested.

    Seen in our tests, 15 October 2026, SiteGround Optimizer 7.8.4.

    Full detail

    With SiteGround Optimizer's JavaScript minify, combine and asynchronous loading on, the page's scripts are combined; the Cookie Rocks head script stays first and untouched, the engine stays separate, the banner shows and the trackers are held until Accept all. SiteGround's dynamic cache needs a SiteGround server and was not part of the test.

How we test it

Around each version, with its latest release

Around each Cookie Rocks version, a fresh WordPress installs its latest version from WordPress.org next to Cookie Rocks and runs the same checks. A new version joins the next run on its own.

  • SiteGround Optimizer 7.8.6, tested on 7 November 2026.
  • The banner shows, the trackers of the test page wait for consent and load after it, and Cookie Rocks raises no PHP error.
  • Settings of the test: Default settings after activation.
  • Last run: SiteGround Optimizer 7.8.6 on 7 November 2026, with WordPress 7.1.3.

Light as a pebble

11.43 kB once, 1.00 kB per page. Measured, not promised.

lighter than the font on this page*

Every kilobyte costs your visitors time and costs you Core Web Vitals. Cookie Rocks adds 11.43 kB to the first page a visitor opens, then 1.00 kB to each page after that, because its files stay in the browser cache. It calls no outside server and never shifts your layout.

11.43 kB First visit, in total

1.00 kB Each next page

7.74 kB JavaScript, first visit

3.48 kB Stylesheet, first visit

0 Requests to other servers

0 Layout shift caused

* The font on this page is Inter, compressed and cut down to the Latin alphabet. It still weighs 26.23 kB.

Questions

Will visitors see each other’s choices in a cached page?

No. The choice is read in the browser, after the page arrives, so the cached page is the same for everyone.

And a CDN in front of SiteGround?

A CDN keeps its own copy. If yours is not cleared with the SiteGround cache, clear it by hand after a banner change.

What happens after the 30-day trial?

The banner, your visitors’ choices and your proofs of consent keep working. Without a key, most settings lock, updates and support stop. Take a key at any time and everything opens again.

For SiteGround sites

Keep SiteGround’s speed, add consent.

four lists, one rule

Every feature of the complete plugin for 30 days, no card.

  • During the trial: everything, including the full settings and the scans
  • After 30 days without a key: the banner, your visitors’ choices and your proofs of consent keep working
  • What waits for a key: most settings, updates and support

How the trial works, in detail

Get your trial key

Your e-mail and your site. Your key arrives as soon as you confirm your e-mail.

One trial per domain. Local and staging sites never use up your key.

We keep your e-mail address to send your key and help you with it, as explained in our privacy policy. No newsletter, nothing else.