The canvas element allows rendering of graphs and visual images directly in the browser. It provides an API for drawing primitives like rectangles, paths, text and images. The API is small but allows drawing complex shapes. However, coding paths can be painful and there is no way to store paths. Browser support for the canvas element is improving but still lacks in some older browsers.