Challenge 2 of 5

Challenge 2: Add a button

Your first hand-typed HTML element.

0 of 5 complete 2/5 ✓ Completed

What you're building

Type a <button> element directly into the code editor. Give it your own text. Then style it in CSS so it feels clickable — padding, rounded corners, maybe a colour that matches your page.

How the editor knows you're done

The code contains the string <button anywhere. That's it. Styling is optional, but the experience is much better if you try.

A starting point

Drop this into the HTML panel:

<button class="my-btn">Click me!</button>

And this into the CSS panel:

.my-btn {
  padding: 10px 20px;
  border-radius: 8px;
  background: #2563eb;
  color: white;
  border: none;
  cursor: pointer;
}

Then change the text, the colour, the padding — make it yours.

Open in editor → Back to all challenges →