My host just stared a new online tool were you can test site and server speeds. It will also give you suggestions in were problems exists and how to improve your site.
Google has mentioned that speed is becoming more important in ranking well on their searches. How true that is no one knows of course:
A “Expires” header is a timestamp sent by your web server to your visitors browser. It instructs a browser to keep a specific piece of data in its cache until the time set by the header is reached. It can be tied to almost any kind of data sent by your server (images, stylesheets, javascripts, web pages).
You could, for example, tell browsers to re-download your logo image only once per month. So, if you have a million page views from returning visits in a month, you just saved your server a theoretical million hits (and about 19 gigabytes of bandwidth if your logo weights 20 kilobytes).
When properly set, it can be a HUGE performance booster and bandwidth saver.
[QUOTE=William Godin;61926]A “Expires” header is a timestamp sent by your web server to your visitors browser. It instructs a browser to keep a specific piece of data in its cache until the time set by the header is reached. It can be tied to almost any kind of data sent by your server (images, stylesheets, javascripts, web pages).
You could, for example, tell browsers to re-download your logo image only once per month. So, if you have a million page views from returning visits in a month, you just saved your server a theoretical million hits (and about 19 gigabytes of bandwidth if your logo weights 20 kilobytes).
When properly set, it can be a HUGE performance booster and bandwidth saver.
Thanks for the info, I wanted to find out more about that actually. Going to test that on some of my sites. It seems to be a excellent way of speeding it up.
Oh and sorry about you having to do 2 posts. “new” users have to have made a few posts before they can include a link in their posts… yours got stuck waiting for approval. Sorry about that.
I’ll have to look into this “Add expires headers” tactic a little more too. I just moved to a dedicated server and anything to save bandwidth is certainly good. Thanks for the info William Godin.
[QUOTE=William Godin;61926]A “Expires” header is a timestamp sent by your web server to your visitors browser. It instructs a browser to keep a specific piece of data in its cache until the time set by the header is reached. It can be tied to almost any kind of data sent by your server (images, stylesheets, javascripts, web pages).
You could, for example, tell browsers to re-download your logo image only once per month. So, if you have a million page views from returning visits in a month, you just saved your server a theoretical million hits (and about 19 gigabytes of bandwidth if your logo weights 20 kilobytes).
When properly set, it can be a HUGE performance booster and bandwidth saver.
I’ve started to use Expire in headers. I’m serving java and design images from a subdomain and with a 1 year expire on them. But I can update them by changing what folder I store them in and a htaccess rewrites makes sure it still works.
But not sure it’s much different, does the site flicker to anyone:
Gay Porn Pig performs pretty badly on speed tests so we will be investing a bit in optimising it. Quite a bit will probably wait until we move it over to a new CMS (probably Gossamer based) - Joomla and some of the extensions seem too resource intensive.
Expires headers can be a pain in the ass if you have a dynamic site that changes after someone logs in. Take this site for example… How would you like it if you got a page that looked like you weren’t logged in after you had actually logged in? That’s the sort of thing expires headers can do to you. It’s even worse if there’s a proxy server involved since the proxy server can cache a page and present it to multiple users - so you may get someone else’s version of the page. They’ve been the bane of my existence at times.
It gets more complicated since “Expires” isn’t the only thing you need to set. “Last-Modified”, “Cache-Control”, and “Pragma” are also HTTP headers that can affect the page caching. And on top of it all, there are HTML meta tag equivalents of each of them - and if they conflict you really have no clue what the browser will do… (Yes, that’s up to 8 elements that all have to be in perfect sync).
Bjorn - I wouldn’t recommend doing a 1 year expires on your Javascript. What if you want to change it? I’d do a few hours at most so all the page loads in a particular session just hit the Javascript once. That’s really the point. The user’s browser cache won’t hold onto the file for a year, so there’s no point in caching for a year.
Also, think about bang for the buck… Text files (HTML, JS, CSS) are small and highly compressible. Images are much better candidates for caching since they take a lot more bandwidth, though in the context of how fast does a particular page load, the overhead of retrieving the JS and CSS more than once can be a small factor. (More important is to make sure they’re not on a different host that requires another DNS lookup and connection).
[QUOTE=rawTOP;62202]
Bjorn - I wouldn’t recommend doing a 1 year expires on your Javascript. What if you want to change it? I’d do a few hours at most so all the page loads in a particular session just hit the Javascript once. That’s really the point. The user’s browser cache won’t hold onto the file for a year, so there’s no point in caching for a year…[/QUOTE]
Ah but there is a very simple way of solving the problem. I only use it for images and scripts that are used on all pages and I have a domain alias + htaccess setup for:
Forcing it to refresh. It’s still the same file and location but just a simple htaccess rewrite that points that alias to the real location. Same with Java.
It’s crazy hard to compute Apdex scorings! For the sake of our sanity, we’ve outsourced that part. (We’re using NewRelic)
Apdex doesn’t calculate business performance per se (sales, etc…). It just takes those hard-to-read technical metrics and transforms them into a measure of user satisfaction.
It basically tells you if the performance of your websites is a source of frustration for your customers in a manner us, non-über-geeks, can understand it.
Happy customers tend to be more loyal. And I just looove loyal customers. lol