Note: If you're running ASP.NET websites, check out our related post on free tools to troubleshoot performance issues.
Website performance is absolutely critical. Your website visitors become more demanding and less patient by the day. If pages don’t load quickly, you risk losing them.
And, after they leave your site, they’ll tell others about it and they won’t come back. Website performance is important to search engines, as well. Google notes that
they take site speed into account for search rankings.
Here are ten quick tips you can use to improve the performance of your website.
1) Optimize your images.
Let’s just state the obvious: larger images result in longer load times (since your browser is pulling down more data). So pick the right size for the job: high-quality images of your products are one thing, while a “follow us on Twitter” image is another.
Also, choose the right image format for the job at hand. You’ll want to know about
the different formats and when to use them. Lastly, be sure to resize images directly, rather than using HTML scaling. Setting width="600" height="220" doesn’t work well – and, you’re still forcing the larger file to be downloaded in full.
2) Optimize your HTML.
Don’t copy/paste from other applications, such as word processors. They can bring over lots of complex HTML that will slow load times on your page.
Also, use simple (not nested) structures in your HTML and stay standards-compliant, as browsers will be able to parse your page more efficiently.
Finally, know that whitespace is good for readability (for humans), but add to the overall size (in bytes) of your page.
3) Reduce HTTP requests.
In addition, look into
image sprites, which allow you to combine several images into one. From there, you can use CSS to dictate which portion of the combined image gets rendered.
4) Use text instead of images.
Balance good design with great performance.
Text renders much faster than images and is far more effective for SEO. Always use text (vs. images) for headers.
5) Minify scripts and CSS.
If it's not absolutely required, it doesn't need to be there: remove whitespace, reduce duplicate entries and remove unused code. Some free resources that can help:
CSS Formatter and Optimiser
6) Use a Content Delivery Network (CDN)
Content Delivery Networks (CDN) can be effective for serving up static content, including images, multimedia and file downloads. They’re known for providing high availability and high performance. Their distributed nature means that content is being served up “closer” to the end user. For more info, check out “7 Reasons to Use a CDN.”
7) Cache your output.
This may be a slightly more advanced topic, but you can optimize performance by performing caching at both the server-side and client (browser) side. Server-side caching limits the number of queries you make to the database server, while browser caching can reduce HTTP requests and payload.
8) Avoid bad requests.
Check for HTTP 404 errors (“Page Not Found”) and avoid re-directs on resources. Also, monitor server errors and work with your developers to address any repeated errors.
9) Enable gzip compression.
Use gzip compression to decrease the size of page content. The resulting page content can be transmitted faster, though this does require additional processing power on the client (browser) side. For more details on setting this up, check out “How To Optimize Your Site With GZIP Compression.”
10) Choose infrastructure wisely.
Whether you’re hosting your website “on premise,” with a hosting provider or with a cloud provider, you’ll get what you pay for. If you’re running a production quality website (i.e. outages can affect your business or organization), avoid shared hosting. Instead, ensure that you hosting infrastructure is dedicated to your site.
White Paper on Website Performance Audits
How to Do a Performance Audit of Your .NET Website
Managing website performance can be a complex undertaking. There are many factors that can play a role, from server resources to application code to network bandwidth.
Oftentimes, improving website performance can be straightforward once you identify the root cause of performance issues. We detail how you can identify performance issues on .NET websites. By using our methods, you can identify the root cause of your performance issues.
Download the white paper now.