a11yphant Homepage

Challenge: Buttons vs. Links
Difficulty Medium

Buttons and anchors (commonly called links), are two elements that make web pages interactive. However, their intended use cases are different: Links (<a>) should send the user to another page or page section, while buttons (<button>) are intended to trigger actions on the current page.

Yet buttons and links are often misused. Developers tend to use the element that looks closest to the screen design rather than the element that matches the action being performed. This challenge will help you differentiate between buttons and links and show you how to style a link as a button and vice versa.