Easy PageSpeed rewrites the URLs on your blog to serve your static resources from your CDN. It also removes query strings to leverage browser caching.
Installation Instructions
To install Easy PageSpeed, please use the plugin installation interface.
- Search for the plugin Easy PageSpeed from your admin menu Plugins -> Add New.
- Click on install.
It can also be installed from a downloaded zip archive.
- Go to your admin menu Plugins -> Add New, and click on “Upload Plugin” near the top.
- Browse for the zip file and click on upload.
Once uploaded and activated, visit the plugin admin page to specify your CDN server (or servers in the Pro version).
What does *Easy PageSpeed* do?
Here is what Easy PageSpeed does when a reader visits one of your blog posts or pages:
- It looks at the HTML being prepared for the reader, and removes all the query strings (things that look like ?ver=4.4.1) from any local links of static resources (files with extensions jpg, jpeg, gif, png, js and css).
- It rewrites all the local links in the page (again, only for files with extensions jpg, jpeg, gif, png, js and css) so that they point to the CDN server that you have specified.
What is a CDN and how do I use it?
Content Delivery Network (CDN) is a collection of geographically distributed servers that mirror and serve you static contents (images, JavaScrip/CSS files, movies etc.) to your readers much faster than your own blog server can. It can speed up your blog tremendously.
The most common (and easiest) type of CDN is the origin-pull kind, where you specify the URL from where it can pull contents. Amazon CloudFront is one such CDN that most bloggers will find useful. While setting up the CDN, you will specify that the contents are to be pulled from your blog, http://yoursite.com/
.
Once a CDN server is set up on Amazon CloudFront (or anywhere else), you will get a URL that you can place instead of http://yoursite.com/
for each of the static resources that you want to serve from your CDN.
To make the CDN URL look nicer, you may want to use your cPanel DNS Zone Editor to define a CNAME. For example, you can have a name like http://cdn.yoursite.com
as your CDN URL.
Since most browsers limit the number of concurrent connection to a server, you may want to define multiple CDNs using the CNAME trick, all pointing to the same URL you got from CloudFront (or your provider). This technique is called domain sharding, and is fully supported in the Pro version of this plugin.
Of course, you need to make WordPress generate HTML with your CDN addresses instead of http://yoursite.com/
for static resources. While it can be done using certain filters (e.g. pre_option_upload_url_path
), it is far more convenient to use this plugin.
Why not let my caching plugin do this job?
Many caching plugins can handle CDNs and query strings. Why use this plugin? Because many of the popular caching plugins are so heavy and feature-rich that they actually slow down your blog, especially on the admin side. Most (90%) of the performance improvements that a caching plugin buys you may be had with this plugin (and a decent PHP accelerator at the server level).
If you like the way this plugin works, you might want to get the Pro version, so that you can benefit from CDN sharding and finer control of what files are served from where.