http-pagespeed #

Rewrites pages and assets on the fly with PageSpeed: it optimises images, minifies CSS and JavaScript and inlines small files. Use it to speed up a site whose pages you cannot easily change. The upstream project has been retired.

Source: upstream source

Directives

pagespeed #

syntax: pagespeed 1 arg;  ·  context: http

!ngx_pagespeed ![Build Status](https://travis-ci.org/apache/incubator-pagespeed-ngx) ngx_pagespeed speeds up your site and reduces page load time by automatically applying web performance best practices to pages and associated assets (CSS, JavaScript, images) without requiring you to modify your existing content or workflow.

Example

pagespeed on;
pagespeed FileCachePath        /var/cache/ngx_pagespeed;
pagespeed RewriteLevel         CoreFilters;
pagespeed EnableFilters         collapse_whitespace,remove_comments;
pagespeed EnableFilters         rewrite_images,recompress_images;

location ~ "\.pagespeed\.([a-z]\.)?[a-z]{2}\.[^.]{10}\.[^.]+" {
    add_header "" "";
}

↑ back to index