{"id":2713,"date":"2019-10-23T10:30:56","date_gmt":"2019-10-23T02:30:56","guid":{"rendered":"https:\/\/www.mondoze.com\/guide\/?post_type=kb&#038;p=2713"},"modified":"2022-10-05T08:02:10","modified_gmt":"2022-10-05T00:02:10","slug":"how-do-i-minify-html-css-and-javascript-to-optimize-my-site","status":"publish","type":"kb","link":"https:\/\/www.mondoze.com\/guide\/kb\/how-do-i-minify-html-css-and-javascript-to-optimize-my-site","title":{"rendered":"How do I minify HTML,CSS and JavaScript to optimise?"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"2713\" class=\"elementor elementor-2713\" data-elementor-settings=\"[]\">\n\t\t\t\t\t\t<div class=\"elementor-inner\">\n\t\t\t\t\t\t\t<div class=\"elementor-section-wrap\">\n\t\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-39e0663 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"39e0663\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t\t\t<div class=\"elementor-row\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-438014e9\" data-id=\"438014e9\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-column-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t<div class=\"elementor-widget-wrap\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-375285a elementor-widget elementor-widget-heading\" data-id=\"375285a\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">How To Minify HTML, CSS, and JavaScript<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-5d6034f3 elementor-widget elementor-widget-text-editor\" data-id=\"5d6034f3\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-text-editor elementor-clearfix\">\n\t\t\t\t<p>Cloudflare users interested in minifying HTML, CSS and JavaScript can activate Auto Minify in their Cloudflare settings. In addition, Auto Minify will remove all unnecessary characters from HTML, JavaScript, and CSS files.\u00a0<\/p><p>However , CSS &amp; JS minification operates on cached CSS and JS files only. <span class=\"word\">LarMirage\u00a0<\/span><span class=\"word\">and\u00a0<\/span><span class=\"word\">Polish\u00a0<\/span><span class=\"word\">arOnce\u00a0<\/span><span class=\"word\">Cloudflare\u00a0<\/span><span class=\"word\">return\u00a0<\/span><span class=\"word\">a\u00a0<\/span><span class=\"word\">HIT\u00a0<\/span><span class=\"word\">cache\u00a0<\/span><span class=\"word\">to\u00a0<\/span><span class=\"word\">the\u00a0<\/span><span class=\"word\">minified\u00a0<\/span><span class=\"word\">browser\u00a0<\/span><span class=\"word\">directory<\/span>. This allows us to deliver a more complete minification result. After that , if you need to enable or disable minification for CSS &amp; JS you will now need to purge your Cloudflare cache to see the effect of any minification change.<\/p><p>The Auto Minify option can be find under the &#8216;Speed&#8217; Section:<\/p><p><img decoding=\"async\" loading=\"lazy\" class=\"alignnone size-medium wp-image-2715\" src=\"https:\/\/www.mondoze.com\/guide\/wp-content\/uploads\/2021\/03\/AutoMinify-300x135.png\" alt=\"\" width=\"300\" height=\"135\" \/><\/p><p>If you encounter any issues with Minification, you can check out our article that explains why Minification may not be working.<\/p>\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>How To Minify HTML, CSS, and JavaScript Cloudflare users interested in minifying HTML, CSS and JavaScript can activate Auto Minify in their Cloudflare settings. In addition, Auto Minify will remove all unnecessary characters from HTML, JavaScript, and CSS files.\u00a0 However , CSS &amp; JS minification operates on cached CSS and JS files only. LarMirage\u00a0and\u00a0Polish\u00a0arOnce\u00a0Cloudflare\u00a0return\u00a0a\u00a0HIT\u00a0cache\u00a0to\u00a0the\u00a0minified\u00a0browser\u00a0directory. This &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"\" href=\"https:\/\/www.mondoze.com\/guide\/kb\/how-do-i-minify-html-css-and-javascript-to-optimize-my-site\"> <span class=\"screen-reader-text\">How do I minify HTML,CSS and JavaScript to optimise?<\/span> Read More \u00bb<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}}},"kbtopic":[53],"kbtag":[110],"mkb_version":[],"_links":{"self":[{"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kb\/2713"}],"collection":[{"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kb"}],"about":[{"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/types\/kb"}],"author":[{"embeddable":true,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/comments?post=2713"}],"version-history":[{"count":8,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kb\/2713\/revisions"}],"predecessor-version":[{"id":21943,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kb\/2713\/revisions\/21943"}],"wp:attachment":[{"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/media?parent=2713"}],"wp:term":[{"taxonomy":"kbtopic","embeddable":true,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kbtopic?post=2713"},{"taxonomy":"kbtag","embeddable":true,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/kbtag?post=2713"},{"taxonomy":"mkb_version","embeddable":true,"href":"https:\/\/www.mondoze.com\/guide\/wp-json\/wp\/v2\/mkb_version?post=2713"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}