Learn HTML Forms by Building a Registration Form - Step 31

I do not understand what I am missing with my code. It looks like I have done what was asked, but it is still telling me to locate the text immediately after the input. I have tried several different variations including what is there now and the same message keeps coming up. The section I need help with is the terms and conditions part of my code where the label and input are.

Your code so far

<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
    <meta charset="UTF-8">
    <title>Registration Form</title>
    <link rel="stylesheet" href="styles.css" />
    <h1>Registration Form</h1>
    <p>Please fill out this form with the required information</p>
    <form method="post" action='https://register-demo.freecodecamp.org'>
        <label for="first-name">Enter Your First Name: <input id="first-name" type="text" required /></label>
        <label for="last-name">Enter Your Last Name: <input id="last-name" type="text" required /></label>
        <label for="email">Enter Your Email: <input id="email" type="email" required /></label>
        <label for="new-password">Create a New Password: <input id="new-password" type="password" pattern="[a-z0-5]{8,}" required /></label>
        <legend>Account type (required)</legend>
        <label for="personal-account"><input id="personal-account" type="radio" name="account-type" checked /> Personal</label>
        <label for="business-account"><input id="business-account" type="radio" name="account-type" /> Business</label>

<!-- User Editable Region -->

      <label for="terms-and-conditions"> <a link="terms and conditions" href="https://www.freecodecamp.org/news/terms-of-service/"></a>
        <input id="terms-and-conditions" type="checkbox" required/>I accept the terms and conditions</label> 

<!-- User Editable Region -->

      <input type="submit" value="Submit" />
/* file: styles.css */
body {
  width: 100%;
  height: 100vh;
  margin: 0;
  background-color: #1b1b32;
  color: #f5f6f7;

label {
  display: block;
  margin: 0.5rem 0;

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.2.1 Safari/605.1.15

Challenge Information:

Learn HTML Forms by Building a Registration Form - Step 31

Welcome to the forum @DANQUACK198

Nest the anchor element around the target words in the label element. At the moment this is no text in the anchor element, so there is nothing to click.

Happy coding

So, I have done that and now its telling me that it needs to be in the label following the third field set that is the third field set there.

I accept theterms and conditions

I got it thank you for your assistance!!

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.