Skip to main content

YSlow: Yahoo's Problems Are Not Your Problems

YSlow: Yahoo's Problems Are Not Your Problems

I first saw Yahoo's 13 Simple Rules for Speeding Up Your Web Site referenced in a post on Rich Skrenta's blog in May. It looks like there were originally 14 rules; one must have fallen off the list somewhere along the way Yahoo support phone number.

  1. Make Fewer HTTP Requests
  2. Use a Content Delivery Network
  3. Add an Expires Header by Yahoo support phone number
  4. Gzip Components
  5. Put CSS at the Top
  6. Move Scripts to the Bottom
  7. Avoid CSS Expressions
  8. Make JavaScript and CSS External
  9. Reduce DNS Lookups
  10. Minify JavaScript
  11. Avoid Redirects
  12. Remove Duplicate Scripts
  13. Configure ETags Yahoo support number
It's solid advice culled from the excellent Yahoo User Interface blog, which will soon be packaged into a similarly excellent book. Yahoo support number It's also available as a powerpoint presentation delivered at the Web 2.0 conference Yahoo phone number.
I've also covered similar ground in my post, Reducing Your Website's Bandwidth Usage Yahoo support phone number.
But before you run off and implement all of Yahoo's solid advice, consider the audience. These are rules from Yahoo, which according to Alexa is one of the top three web properties in the world. And Rich's company, Topix, is no slouch either-- they're in the top 2,000. Yahoo phone number It's only natural that Rich would be keenly interested in Yahoo's advice on how to scale a website to millions of unique users per day Yahoo phone number.
To help others implement the rules, Yahoo created a FireBug plugin, YSlow. This plugin evaluates the current page using the 13 rules and provides specific guidance on how to fix any problems it finds. Yahoo phone number And best of all, the tool rates the page with a score-- a score! There's nothing we love more than boiling down pages and pages of complicated advice to a simple, numeric score. Here's my report card score for yesterday's post-Yahoo support phone number.
yslow performance score
To understand the scoring, you have to dissect the weighting of the individual rules, as Simone Chiaretta did: Yahoo phone number
Weight 113. Add an Expires Header
4. Gzip Components
13. Configure ETags
Weight 102. Use a Content Delivery Network
5. Put CSS at the Top
10. Minify JavaScript
11. Avoid Redirects
Weight 59. Reduce DNS Lookups
6. Move Scripts to the Bottom
12. Remove Duplicate Scripts
Weight 41. Make Fewer Requests (CSS)
1. Make Fewer Requests (JS)
Weight 31. Make Fewer Requests (CSS background images)
Weight 27. Avoid CSS Expressions by Yahoo support number
My YSlow score of 73 is respectable, but I've already made some changes to accommodate its myriad demands. To get an idea of how some common websites score, Yahoo support number Simone ran YSlow on a number of blogs and recorded the results: Yahoo customer service number
YSlow is a convenient tool Yahoo support number, but either the web is full of terribly inefficient web pages, or there's something wrong with its scoring. I'll get to that later.
The Stats tab contains a summary of the total size of your downloaded page, along with the footprint with and without browser caching. One of the key findings from Yahoo is that 40 to 60 percent of daily visitors have an empty cache. So it behooves you to optimize the size of everything and not rely on client browser caching to save to you in the common case Yahoo support phone number.
yslow stats
YSlow also breaks down the statistics in much more detail via the Components tab. Yahoo customer service number Here you can see a few key judgment criteria for every resource on your page...
  • Does this resource have an explicit expiration date?
  • Is this resource compressed?
  • Does this resource have an ETag?
... along with the absolute sizes.
yslow components
YSlow is a useful tool, but it can be dangerous in the wrong hands. Software developers love optimization. Yahoo customer service number Sometimes too much.
There's some good advice here, but there's also a lot of advice that only makes sense if you run a website that gets millions of unique users per day. Do you run a website like that? If so, what are you doing reading this instead of flying your private jet to a Bermuda vacation with your trophy wife? The rest of us ought to be a little more selective about the advice we follow. Avoid the temptation to blindly apply these "top (x) ways to (y)" lists that are so popular on Digg and other social networking sites. Instead, read the advice critically and think about the consequences of implementing that advice Yahoo customer service number.
If you fail to read the Yahoo advice critically, you might make your site slower, as Phil Haack, unfortunately, found out. While many of these rules are bread-and-butter HTTP optimization scenarios, it's unfortunate that a few of the highest-weighted rules on Yahoo's list are downright dangerous, if not flat-out wrong for smaller web sites. And when you define "smaller" as "smaller than Yahoo", that's.. well, almost everybody. So let's take a critical look at the most problematic heavily weighted advice on Yahoo's list.
Use a Content Delivery Network (Weight: 10)
If you have to ask how much a formal Content Delivery Network will cost, you can't afford it. It's more effective to think of this as outsourcing the "heavy lifting" on your website-- eg, any large chunks of media or images you serve up -- to external sites that are much better equipped to deal with it. This is one of the most important bits of advice I provided in Reducing Your Website's Bandwidth Usage. And using a CDN, below a reasonably Yahoo-esque traffic volume, can even slow your site down Yahoo customer service number.
ETags are a checksum field served up with each server file so the client can tell if the server resource is different from the cached version the client holds locally. Yahoo recommends turning ETags off because they cause problems on server farms due to the way they are generated with machine-specific markers. So unless you run a server farm, you should ignore this guidance. Yahoo helpline phone number It'll only make your site perform worse because the client will have a more difficult time determining if its cache is stale or fresh. Yahoo customer service phone number It is possible for the client to use the existing last-modified date fields to determine whether the cache is stale, but last-modified is a weak validator, whereas Entity Tag (ETag) is a strong validator Yahoo customer service phone number. Why trade strength for weakness?
Add an Expires Header (Weight: 11)
This isn't bad advice, per se, but it can cause huge problems if you get it wrong. In Microsoft's IIS, for example, the Expires header is always turned off by default, Yahoo helpline phone number probably for that very reason. Yahoo customer service phone number By setting an Expires header on HTTP resources, you're telling the client to never check for new versions of that resource-- at least not until the expiration date on the Expires header. When I say never, I mean it -- the browser won't even ask for a new version; it'll just assume its cached version is good to go until the client clears the cache, or the cache reaches the expiration date. Yahoo notes that they change the filename of these resources when they need them refreshed Yahoo customer service phone number.

All you're really saying here is the cost of the client pinging the server for a new version and getting a 304 not modified header back in the common case that the resource hasn't changed. That's not much overhead.. unless you're Yahoo. Sure, if you have a set of images or scripts that almost never change, definitely exploit client caching and turn on the Cache-Control header. Yahoo helpline phone number Caching is critical to browser performance; every web developer should have a deep understanding of how HTTP caching works. But only use it in a surgical, limited way for those specific folders or files that can benefit. For anything else, the risk outweighs the benefit. It's certainly not something you want to be turned on as a blanket default for your entire website.. unless you like changing filenames every time the content changes.
I don't mean to take anything away from Yahoo's excellent guidance. Yahoo customer service phone number 13 Simple Rules for Speeding Up Your Web Site and the companion FireBugplugin, YSlow, are outstanding resources for the entire internet. By all means, read it. Yahoo helpline phone number Benefit from it. Implement it. I've been banging away on the benefits of GZip compression for years.
But also realize that Yahoo's problems aren't necessarily your problems. There is no such thing as one-size-fits-all guidance. Strive to understand the advice first, then implement the advice that makes sense for your specific situation Yahoo helpline phone number.

Comments

Popular posts from this blog

Quicken 2019 Troubleshooting Tips

Quicken 2019 Troubleshooting Tips by Quicken support phone number When using Quicken 2019, you probably want not only specific, step-by-step information about how to use the program, but also troubleshooting advice. Following are some techniques and tactics that you can use to solve the inevitable problems you encounter while using Quicken in real-life settings  Quicken support phone number. Tactic #1: Use the Quicken Help file  Quicken support number You have some problem that you can’t solve by using Help, and it’s either a bug or some glaring error in the Quicken documentation. Upon further reflection, you may be thinking that you’ve encountered some problem that you can’t possibly solve by consulting the  Quicken support phone number  Help file. Maybe you’re right. But about half the time, the problem is that people don’t know enough about Quicken to know what to do. People simply experience a mechanical problem, and they can’t make the ...

How to fix Malwarebytes memory issues

Malwarebytes is a great antimalware tool, however, many users reported Malwarebytes support phone number memory issues. It seems that this application is using more memory than it should, and this can be a big problem and drastically impact your performance. However, there’s a way to fix this issue by Malwarebytes support phone number. Malwarebytes is a solid antimalware tool, but sometimes Malwarebytes memory issues can occur and cause various problems. Speaking of memory issues, here are some problems that users reported: Malwarebytes high memory usage windows 10, CPU usage Windows 10  – Sometimes high CPU or memory usage can appear with Malwarebytes. If that’s the case, try ending the process and change its priority to low Malwarebytes support phone number. Malwarebytes freezes computer  – This can be a serious problem, and in most cases, it’s caused by a corrupted installation. To fix the problem, update Malwarebytes to the latest version and check if that helps....

5 Most Common BitDefender Issues And How To Solve Them

BitDefender is one of the best online security suites on the market, but that doesn’t mean it isn’t without issues. Given the vast number of applications and uses it has to contend with, there’s bound to be a few problems here and there. Fortunately, these problems can be solved. Here are some of the most common BitDefender issues you might run into and what you can do about them  Bitdefender support phone number. 1. SSL Scanning BreaksSecure Sites and Apps by Bitdefender support phone number One common Bitdefender customer service number  problem appears to be a conflict with Microsoft Outlook, the popular email and time management tool. But upon closer inspection, it seems that the issue here is less about the application itself and more to do with SSL certificates. This particular issue can also crop up with websites and even some online games. If you’re having a problem with SSL certificates that cannot be verified (usually due to them be...