W
by Steven Vachon 3.4 (14 reviews)

WP-HTML-Compression

Reduce file size by shortening URLs and safely removing all standard comments and unnecessary whitespace from an HTML document.

WP-HTML-Compression ranks #6,878 among WordPress.org plugins with 1,000+ active installations, is #196 of 2,881 in the Discussion & Community category, a 3.4/5 rating from 14 reviews, and was last updated Nov 28, 2017. Data from WordPress.org, refreshed twice daily — see methodology.

Tested up to WP 3.5.2 (Current: 7.1)
v0.5.8 Current Version v0.5.8
Updated 8 years ago Last Update on 28 Nov, 2017
Refreshed 15 hours ago Last Refreshed on
#196 of 2,881 in Discussion & Community Top 10% by installs No update in over a year
View on WordPress.org
Rank
#6,878
+3 this week
Active Installs
1K+
-13.2%
KW Avg Position
N/A
No change
Downloads
108.6K
+5 today
Support Resolved
0%
No change
Rating
68%
Review 3.4 out of 5
3.4 (14 reviews)

Next Milestone 2K

Total Progress 3.1%
1K+ 2K+
6,829
Ranks to Climb
-
Growth Needed
8,000,000
Active Installs
Pro

Unlock Exact Install Count

See the precise estimated active installs for this plugin, calculated from real-time ranking data.

  • Exact install estimates within tiers
  • Track install growth over time
  • Milestone progress predictions
Upgrade to Pro
Need 969 more installs to reach 2K+

Rank Changes

6,865 6,871 6,877 6,882 6,888 09-09-2026 10-09-2026 11-09-2026 12-09-2026 13-09-2026 14-09-2026 15-09-2026 16-09-2026
6,842 6,853 6,865 6,877 6,888 01-09-2026 02-09-2026 03-09-2026 04-09-2026 05-09-2026 06-09-2026 07-09-2026 08-09-2026 09-09-2026 10-09-2026 11-09-2026 12-09-2026 13-09-2026 14-09-2026 15-09-2026 16-09-2026
Current #6,878
Change
Best #

Upgrade to Pro

Unlock 30-day and 90-day rank history charts with a Pro subscription.

Upgrade Now

Active Installs Growth

Active Installs 0,000,000+
Growth +0.0%
Peak 0,000,000

Downloads Growth

0 10 09-09-2026 10-09-2026 11-09-2026 12-09-2026 13-09-2026 14-09-2026 15-09-2026 16-09-2026
0 10 01-09-2026 02-09-2026 03-09-2026 04-09-2026 05-09-2026 06-09-2026 07-09-2026 08-09-2026 09-09-2026 10-09-2026 11-09-2026 12-09-2026 13-09-2026 14-09-2026 15-09-2026 16-09-2026
Downloads
Growth
Peak

Upgrade to Pro

Unlock 30-day, 90-day, and yearly download history charts with a Pro subscription.

Upgrade Now

Reviews & Ratings

3.4
14 reviews
Overall 68%
5
6 (43%)
4
2 (14%)
3
1 (7%)
2
1 (7%)
1
4 (29%)

Security History

Source: WPVulnerability

No known vulnerabilities on record for WP-HTML-Compression. Checked 1 month ago.

TL;DR

AI summary of the plugin's readme

This plugin is for WordPress site administrators who want to reduce the size of their HTML pages. It compresses HTML output by shortening URLs and stripping comments and unnecessary whitespace, without affecting page presentation.

  • Shortens URLs
  • Removes standard HTML comments
  • Removes unnecessary whitespace
  • Removes new lines and carriage returns
  • Removes tabs and excess spaces
  • Ignores conditional comment tags
  • Compatible with WP Super Cache

Frequently Asked Questions

Common questions about WP-HTML-Compression

Upload and activate the plugin through the "Plugins" menu in the WordPress admin.
Yes, slightly. While you should be using WP Super Cache anyway, it will correct the issue.
No.
Yes.
Probably, however WordPress does a pretty good job of correcting invalid markup. But honestly, it's your job to make sure that your code doesn't suck.
If the links in your HTML are not hard-coded as hashes without the use of a script, an issue could occur with URL shortening. If so, setting $shorten_urls on line 21 of libs/html-minify.php to false will fix that.
This is totally fine and actually intentional. It's standard and will not cause 404s nor get in the way of your SEO, but it will lower file size! You might be interested in reading more about this technique, called scheme-relative URLs.
To preserve rendered whitespace. One or more line breaks in your markup are rendered as a single space in a web browser. Visual discrepancies would occur if those line breaks were not converted to at least one space.
While <pre>, <textarea> and <script> tags are automatically left uncompressed, you can designate any code to be exempted from compression. Simply drop your content between a pair of <!--wp-html-compression no compression--> comment tags. A picture is worth a thousand words; so, check the screenshots.
Until a settings page is created, you'll have to edit the file from the "Plugins" menu in the WordPress admin. Set $compress_js on line 21 of libs/html-minify.php to true. This is not recommended as this plugin is not yet ready to properly compress inline scripts.

Sign In / Register

You need to sign in or register to use this feature.