Nice set of performance tips for jQuery selectors:

They are all quite logical if you are used to selecting from data sets or file hierarchies. More specificity = faster selection; don’t do the same “query” twice.

Remember, the DOM is a data source. With an API as simple as jQuery’s, it’s easy to forget about the work being done underneath.