Monday, April 18, 2011

HTML Optimization Techniques

Below are some of the techniques for HTML optimization:
1) Minimal Meta Tags usage: Minimizing the size of page's HEAD is an effective means to achieve quicker parsing of the HEAD, followed by the rest of the content of your website, in equally quick succession. The conditional SSI META tags with 200 characters or less and HTML lines with maximum 255 characters fetch favorable search engine results by saving space for browsers visiting your site. Further, there's no need to use commas to separate keywords, as search engines ignore the commas.
2) CSS Layout: Inline CSS will slow down the process page loading and page rendering. Always it will be better to link an external css file to the HTML file. Don't use import statement for css loading.
3) Javascript: Optimization of JavaScript is achieved with short variable names and no spaces etc, which speeds up the display of Web Pages. Avoid writing javascript in HTML file. Always include this javascript file at the end of the page to improve page loading speed.
4) Use DIVs rather than Tabes: Tables will load very slowly compare to DIV. We can achieve complete table layout by using Divs with simple CSS.
5) URL Abbreviation: By abbreviating URL using Apache's mod_rewrite module, we achieve effective cut down to your HTML file size.
6) HTML Compression: Compressing your HTML using utility like mod_gzip, automatically cuts down size of the web page for as much as 40% bandwidth and thus speeds up the page display immensely.
7) Reduce Images: Try to use low size image files in the layout. And try to reduce image backgrounds and achieve it by css properties.
8) Use Sprites: By using Sprites we can reduce maximum number of image requests on server. We can simply use one image for several image displays by modifying its position by using CSS.
9) Use multiple servers for external files: Try to store images and external javascript and css files in sub domains and try to use them in the webpage. By this way both html an images will be loaded simultaneously.

1 comment:

  1. Point 9: how it differs from traditional method???
    How you can say that it will load simultaneously??

    ReplyDelete