Validate your code.

Why?

Well, the W3C can tell you why you should validate your code, and they do a much better job of telling you what you need to know than I would. But I will list the basic reasons if you can’t be bothered to click the link:

  • Validation used as a debugging tool
  • Future-proof quality checking
  • Helps teach good practices
  • Gives a sign of professionalism

How?

There’s a great little Firefox add-on called HTML Tidy. In conjunction with viewing the source of a page, you can easily track down invalid code to set it back on the straight and narrow.

You can also use the online W3c HTML Validation Service and the online W3c CSS Validation Service if you develop using other browsers.