if (typeof canvas.getContext != "undefined") { .... } else { alert("Sorry, your browser doesn't support wicked cool graphics. Please download one that supports wicked coolness."); ... }