39252

gzip compression is not detected by PageSpeed Insights (node.js)

Question:

I build my gzip-files with gulp (<strong>gulp-gzip</strong>) and use them with npm package <strong>connect-gzip-static</strong>:

<pre class="snippet-code-js lang-js prettyprint-override">var app = express(); var serveStatic = require('connect-gzip-static'); //... app.use(serveStatic(__dirname)).listen(3000);

However, PageSpeed Insights does not detect the gzip compression.

But google chrome developer console it says: Response Headers: Content-Encoding: gzip. Also other seo testing tools are detecting gzip. Why Google doesen't ?

I gziped all html, js, css. Should I also gzip svg's ? Thanks!

Answer1:

PageSpeed Insights should tell you which resources are not gzipped.

Often they are third party resources out of your control, or it may be types like SVG that you have not enabled yet.

PageSpeed Insights should be taken as a guide and not gospel. It's easy to become hung up on it. Especially if you ignore the bigger reasons your site is slow to save a few bytes on one resource.

Recommend

  • Trying to change an image's position and size at the same time
  • Css optimization for google pagespeed insight
  • Should I handle redirection via PHP or Javascript?
  • ASP.NET sitemap , how important?
  • How to create unicode slug for unicode title?
  • .htaccess url rewrite and removing %20 [duplicate]
  • How to use C# encode and decode 'Chinese' characters
  • How to intercept a Url to dynamically change the routing
  • Match array words against string
  • Jquery page transitions and SEO
  • Angular2 set meta title and description
  • How to do a specific condition for escaped_fragment with rewrite rule in .htaccess
  • ASP.Net check if user is internal or external
  • NetBeans refactor class: java.lang.NoClassDefFoundError
  • Simple command-line app I/O in Dart
  • Can't configure nginx as a proxy for tomcat with context path
  • What is wrong in my MVC implementation?
  • Facebook Messenger Platform - Detect user typing
  • Unix Network Programming Clarification
  • Unzip archive in .Net CORE 1.0
  • Save image as is in photo album using swift
  • File extension of zlib zipped html page?
  • Using MouseListener to select a range of cells in a grid
  • git add error : “fatal : malloc, out of memory”
  • Jquery popup on mouse over of calendar control
  • Is playing sound in Javascript performance heavy?
  • Chrome doesn't support silverlight anymore? How to solve this?
  • Seeking advice on Jetty HttpClient Hang
  • Ajax Loaded meta Tags
  • Ajax jQuery multiple calls at the same time - long wait for answer and not able to cancel
  • How to make a tree having multiple type of nodes and each node can have multiple child nodes in java
  • Deserializing XML into class C#
  • Can I make an Android app that runs a web view in Chrome 39?
  • Javascript convert timezone issue
  • Google cloud sdk not working when python points python3
  • Load html files in TinyMce
  • Free memory of cv::Mat loaded using FileStorage API
  • using HTMLImports.whenReady not working in chrome
  • costura.fody for a dll that references another dll
  • Android Heatmap on canvas or ImageView