Installing From Packages

If you're using Nginx you need to build from source. These packages are Apache-only.

Supported platforms

  • CentOS/Fedora (32-bit and 64-bit)
  • Debian/Ubuntu (32-bit and 64-bit)

To install the packages, on Debian/Ubuntu, please run the following command:

sudo dpkg -i mod-pagespeed-*.deb
sudo apt-get -f install

For CentOS/Fedora, please execute:

sudo yum install at  # if you do not already have 'at' installed
sudo rpm -U mod-pagespeed-*.rpm

Installing mod_pagespeed will add the Google repository so your system will automatically keep mod_pagespeed up to date. If you don't want Google's repository, do sudo touch /etc/default/mod-pagespeed before installing the package.

You can also download a number of system tests. These are the same tests available on

What is installed

  • The mod_pagespeed packages install two versions of the mod_pagespeed code itself, for Apache 2.2 and for Apache 2.4.
  • Configuration files: pagespeed.conf, pagespeed_libraries.conf, and (on Debian) pagespeed.load. If you modify one of these configuration files, that file will not be upgraded automatically in the future.
  • A standalone JavaScript minifier pagespeed_js_minify based on the one used in mod_pagespeed, that can both minify JavaScript and generate metadata for library canonicalization.

How to upgrade

To upgrade from a previous version, use the standard yum or apt-get update commands. For example:

sudo yum update mod-pagespeed-beta  # Or mod-pagespeed-stable
sudo /etc/init.d/httpd restart
sudo apt-get update
sudo apt-get upgrade
sudo /etc/init.d/apache2 restart

How to Change Channels

To convert from one channel to another, uninstall one and re-install the other. For example, if you would like to move from stable to beta channel:

sudo yum remove mod-pagespeed-stable
sudo yum install mod-pagespeed-beta
sudo apt-get remove mod-pagespeed-stable
sudo apt-get install mod-pagespeed-beta