Chapter 11
Beginner
8 min read
Forms & Input
Input Types
HTML5 introduced many new input types that improve usability and provide built-in validation on mobile and desktop.
🎯 What you'll learn
✓Use text, email, password,
number inputs
✓Pick dates with type=date
✓Use checkboxes, radio and range
inputs
✓Understand input validation
attributes
Introduction to Input Types
This chapter covers Input Types in depth. Understanding this topic is essential for writing clean, modern HTML. Use the live editor below to experiment as you read.
💡 In This Chapter
You will see real code examples, clear
explanations, and a live editor to practice immediately — no setup needed.
Common Types
Frequently used inputs.
HTML
<input type="text" placeholder="Name">
<input type="email" placeholder="Email">
<input type="password" placeholder="Password">
<input type="number" min="1" max="100">
Selection Types
Checkbox and radio.
HTML
<input type="checkbox"> Subscribe
<input type="radio" name="gender"> Male
<input type="date">
<input type="color">
Try It Yourself
Edit the code below and click ▶ Run to see your changes live.
Live Editor
✎ Editor
👁 Preview
❓ Quick Check — Chapter 11
Which input type shows a date picker on most browsers?
📄 Chapter Summary
- Use text, email, password, number inputs
- Pick dates with type=date
- Use checkboxes, radio and range inputs
- Understand input validation attributes