Speed up your WordPress site with PageSpeed

Mar 3, 2014

Speed up your WordPress site with PageSpeed

Mar 3, 2014

A slow website is a big turn off. It not only dissuades people from visiting your site but also has a big impact on your site’s rankings. If you have a slow website, you are in trouble. But like a wise man once said, “Every problem has a solution”. Google’s PageSpeed Service is the answer to your problem.

PageSpeed Service is an optimization tool that speeds up your site by applying the best practices of web performance. These optimizations include combining and minifying JavaScript and CSS files, resizing images to specified dimensions, re-encoding images to specified formats, and others.

Adding your domain on PageSpeed kick-starts the optimization process. PageSpeed rewrites your content based on standard optimization rules. After this, it stores the re-written content on its own high-end servers. From this point onwards, your optimized content is meant to be served from Google’s fast servers. But your URL is originally hosted on a provider. In order to redirect all requests to your URL to Google’s servers, you need to add a CNAME record in the DNS manager pointing to PageSpeed’s server.

Setting up PageSpeed

The PageSpeed service is currently in beta and hence operates on an invite-only basis. To set up PageSpeed for your site, enter your email address and your site URL here.

Once your account is approved, Google will send an email to you for the activation of your account within an hour or so. Using the link specified in the email, you can login with your Google credentials.

Now we can begin the actual setting up of PageSpeed. This involves two steps – entering your site’s URL and creating a CNAME record.

Note: Google wants to ensure that your own the domain specified in this step. So it prompts you to claim ownership of it by following a set of instructions.

Once you add the URL, you can proceed with the DNS update. Add a record of type CNAME pointing to pagespeed.googlehosted.com for the domain which needs to be optimized using your host’s cPanel.

Note: If your website serves pages over SSL, consult the SSL Setup Guide to support SSL traffic on your site, before proceeding with the DNS change

That completes the PageSpeed service setup for your domain.

Speed Comparison Test

It’s time for results! Let us test if there is a performance improvement, post-optimization, on our site. To do this, we used the Run speed test option provided by Google.

The resultant increase in the page load time was 18.3%! Now that would really make a difference to our visitors, wouldn’t it?

Limitations of PageSpeed Service

  • PageSpeed Service currently does not support serving pages from bare domains, e.g. http://example.com. To solve this problem, you must configure your server to perform a server-side redirect (termed a “301 redirect”) from your bare domain to your full domain, e.g. http://www.example.com.

  • Files larger than 64MB can’t be served.

  • Certain server configurations such as POST request size and IPv6 address isn’t supported. If in doubt, check with your host if it will work fine with PageSpeed.

  • As part of the optimization, PageSpeed may re-compress and/or re-encode images. They may also be moved to a new location. These changes may affect the search engine’s image rankings.

  • Not supported if your host server is located in specific countries such as Syria, Iran, North Korea, Cuba, Sudan, and Myanmar.

Other Options

Caching Plugins

If you are a WordPress user, you might be thinking, “There must be a plugin to do what PageSpeed does.” And you’re right. The W3 Total Cache (W3TC) plugin does most of the CSS and JavaScript optimizations. But using PageSpeed Service may benefit you as there is a reduction in server resources as the optimization is performed on Google’s servers. Also, Google’s geo-distributed edge servers serve your website, giving a big boost to its speed. The latest version of W3TC allows you to integrate with Google’s PageSpeed thus bringing the best overall performance to your site.


CloudFlare is a Content Delivery Network (CDN) that improves site performance and speed. CDN means that content loads faster if it’s geographically located close to the visitors of a site. But this will only benefit you if there is a CDN presence in the countries from which a majority of your traffic originates from.

Setting up CloudFlare for our site was a little tricky, contrary to the reports that it is easier than PageSpeed. We were trying to set up a trial account and that required an update to the name servers of our domain. We had to use the nameservers of CloudFlare’s instead. After some searching on the Internet, we finally found a way to change nameservers on InMotion hosting. Once updated, the account can take up to 24 hours to come into effect.

CloudFlare provides standard security measures (prevention against SQL injections and DDoS). If you are particular about security, you might already have a setup such as ModSecurity (which is free!) in place. CloudFlare also performs compression using best practices just like PageSpeed.


Having a fast website may not be critical to every business, but you can definitely score brownie points by having a responsive site. In today’s fast-paced world, no one likes anything that is slow. PageSpeed is an excellent service that greatly benefits your site by speeding it up. As someone rightly said, “There are no speed limits on the road to success”.

PageSpeed isn’t meant for large, established sites that already have a dedicated hosting in place. If you have a small site hosted on a shared server, then you must definitely give PageSpeed a try.

Would love your thoughts, please comment.x