1

We were trying to optimise the website using google pagespeed and now having some issue:

  1. We're using nginx_pagespeed module
  2. Trying to enable the prioritize_critical_css filter
  3. Since the CSS files are loading from external CDN domain, the critical css filter is not working.
  4. When ran with the ?PageSpeedFilters=debug, the following error is generated in the html source

    Summary computation status for CriticalCssBeacon

    Resource 0 https://mycdndomain.com/styles/screen-2d470013.css: Cannot create resource: either its domain is unauthorized and InlineUnauthorizedResources is not enabled, or it cannot be fetched (check the server logs)

Where mycdndomain is our CDN domain.

Can someone help me fixing this issue. What nginx pagespeed configuration changes are required ?

Also what is the InlineUnauthorizedResources ?

  • 1
    Im not a pagespeed expert, but the standard practice is to minify and combine your critical CSS files locally and then serve them from a CDN. So what mod pagespeed would do is take a bunch of css files, combine and minify them on your server. Then NginX or modPagespeed if it can, would rewrite the urls to your CDN. Lastly your cdn (if it supports pull zones, all except Azure CDN do) would fetch the file and store it on their cdn as needed. – Frank Sep 30 '14 at 14:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.