HTML Compression Tutorial
HTML compression tools can help you lower the size of your HTML file. However, you don't have to use external tools, here are some tips you can use to bring down the overheads:
- Use tabs rather than spaces. Even though the result looks the same, a tab space is a single character whereas the four or eight spaces most commonly used to indent code are one character each.
- Remove all unnecessary comments from your source code. Leave only the important ones. Something like <!--sidebar begins here--> might come in handy at some point, whereas you can leave without <!--I should really change this piece of code to something more readable-->
- Trim all repeating white space. There's no need to be clugging up your HTML file with blanks, Use the search feature in your editor to find " " (double space) and replace it with " " (single space).