{"id":17187,"date":"2024-05-22T12:23:25","date_gmt":"2024-05-22T12:23:25","guid":{"rendered":"https:\/\/hostvento.com\/kb\/web-hosting\/getting-started-guide\/shared-hosting-quick-start-guide\/how-to-enable-gzip-compression-for-nginx-per-site\/"},"modified":"2024-06-16T15:20:18","modified_gmt":"2024-06-16T15:20:18","slug":"how-to-enable-gzip-compression-for-nginx-per-site","status":"publish","type":"docs","link":"https:\/\/www.hostvento.com\/kb\/docs\/hosting-faqs\/how-to-enable-gzip-compression-for-nginx-per-site\/","title":{"rendered":"How to Enable gzip Compression for Nginx Per Site"},"content":{"rendered":"\n<p>Nginx typically disables gzip compression while serving files. The filesize of CSS and Javascript files can be decreased by using gzip compression if they are not already minified or pre-compressed. This tutorial will show you how to activate it for each site on a Plesk 12.5 or Onyx-based server.<br><strong>Guidelines<\/strong><\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Login to your Plesk server.<\/li>\n\n\n\n<li>From the left hand side, select the domain that you want to enable\u00a0<strong>gzip<\/strong>\u00a0for.<\/li>\n\n\n\n<li>Click on\u00a0<strong>Apache and nginx settings<\/strong>\u00a0as below:<br><a href=\"https:\/\/www.hostvento.com\/kb\/hosting-faqs\/wp-content\/uploads\/2019\/08\/nginx-enable-gzip-per-domain-min.png\"><\/a><\/li>\n\n\n\n<li>At the bottom, add the following to the\u00a0<strong>\u201cAdditional nginx directives\u201d<\/strong>\u00a0field:gzip on; gzip_disable \u201cMSIE [1-6]\\.(?!.*SV1)\u201d; gzip_proxied any; gzip_types text\/plain text\/css application\/x-javascript application\/javascript text\/xml application\/xml application\/xml+rss text\/javascript image\/x-icon image\/bmp image\/svg+xml; gzip_vary on;<\/li>\n\n\n\n<li>In order to save, click on\u00a0<strong>OK<\/strong>.<\/li>\n<\/ol>\n\n\n\n<p>The working of gzip compression can be verified by using your browser\u2019s debug tools or third party website such as GTMetrix.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Nginx typically disables gzip compression while serving files. The filesize of CSS and Javascript files can be decreased by using gzip compression if they are not already minified or pre-compressed. This tutorial will show you how to activate it for each site on a Plesk 12.5 or Onyx-based server.Guidelines The working of gzip compression can [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":23377,"menu_order":1151,"comment_status":"closed","ping_status":"closed","template":"","doc_tag":[],"class_list":["post-17187","docs","type-docs","status-publish","hentry","no-post-thumbnail"],"acf":[],"_links":{"self":[{"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/docs\/17187","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/comments?post=17187"}],"version-history":[{"count":2,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/docs\/17187\/revisions"}],"predecessor-version":[{"id":17190,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/docs\/17187\/revisions\/17190"}],"up":[{"embeddable":true,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/docs\/23377"}],"wp:attachment":[{"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/media?parent=17187"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/www.hostvento.com\/kb\/wp-json\/wp\/v2\/doc_tag?post=17187"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}