Web Design. Web Development. Web Hosting.
0 items

How to debug mod_pagespeed with cURL

Need some help? We are here for you!

We have a very friendly service - Come and chat to us and let us know what you need, we work for an hourly fee and can also provide you a no obligation quote and begin work immediately in most cases. Click "Request Support" or use our Live Chat.

Request support

If you ever wondered what mod_pagespeed was doing, why it was skipping some resources or you just want to make sure it is not having any difficulty then there is an easy way to debug any page of any website using a cURL request. This is especially useful when you are trying to configure mod_pagespeed to compress images on a website, I personally have had many issues where certain configuration is needed so that mod_pagespeed can access and cache the resources and you end up trying multiple guides to figure out the issue, now you dont have to!

Open an SSH terminal and run the following command, this command will fetch a url with mod_pagespeed debug turned on and will write the output to a file in the current directory, so you might want to CD to a familiar location first.

 

curl -H "PageSpeedFilters: +debug" https://www.mywebsite.com -o modpagespeeddebug.txt

 

Once complete open modpagespeeddebug.txt in your favourite editor and you will see it is a full snapshot of the HTML source of the page, however next to various resources you will see HTML comments which are debug strings from mod_pagespeed. By reading the debug you should have a clearer understanding of what if anything is going wrong.

And finally at the very bottom of the output you will see a list of the filters and settings currently active.

Have fun!

0 0 votes
Article Rating
Need some help? We are here for you!

We have a very friendly service - Come and chat to us and let us know what you need, we work for an hourly fee and can also provide you a no obligation quote and begin work immediately in most cases. Click "Request Support" or use our Live Chat.

Request support
Author: Dean WilliamsProfessional PHP Web Developer with expertise in OpenCart Web Development, WordPress Web Development, Bespoke Systems - also a seasoned Linux Server Administrator.


Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments


Share this page..

Let's begin your journey...

Get in touch us now to begin your journey to having a beautifully crafted mobile responsive website. If you're still unsure what we could do for you then take a look at our why us page which includes reviews, or take a look at our portfolio.

We can work on improving existing websites or craft a new stylish website making your business stand out.

You could always catch us by email, telephone, Skype or live chat to us below.


    0
    Would love your thoughts, please comment.x
    ()
    x