Web Site Performance

I came across a post on StackOverflow.com regarding web site performance. Quite often you can take a look at your application and find 10 different ways to make it more efficient. Depending on your environment, you may have many different ways to increase performance. For instance, in a shared hosting environment, you’ll likely be limited as to what you can do on the server, but can tweak your application appropriately.


Here are a few things I’d recommend:


  1. Compress your HTML output using built-in compression or third party software like GZip.
  2. If you are using ASP.NET, make sure you minimize your ViewState by turning it off for everything and then determining what items actually need it. ViewState can add quite a bit to your output and as site hits begin to add up, so won’t your traffic.
  3. Move your images, CSS, and JavaScript files to a content delivery network (CDN) or sub-domain. Keep in mind that there are many parts to retrieving a site such as server through-put and bandwidth. At a minimum, you should use a sub-domain to send your files to the browser. This will allow the browser to load your page completely, even if the images, CSS, and JavaScript are not done loading. Finally, when using traffic tools, your images and other files will dominate the results. By moving your content files to another domain, you can provide better traffic reports.
  4. JavaScript files should be at the bottom of your HTML output. If your JavaScript files are at the top of the page and are rather large in size, the browser will attempt to download those before continuing down the page.
  5. Use a tool like CompressJavaScript.com to compress your JavaScript files. It’s also a good idea to compress your CSS.

If you have any more tips, or corrections to anything that I’ve listed above, be sure to comment about it here.


Digg this story here: http://digg.com/programming/Web_Site_Performance

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>