Skip to content
Related Articles

Related Articles

Save Article
Improve Article
Save Article
Like Article

How to add Radio Buttons in form using HTML ?

  • Last Updated : 22 Jul, 2021

We know that Radio Buttons are used to select only one option out of the several options. It is generally used in HTML form. 

Approach: To add a radio buttons in a webpage, the HTML provides a <input> element with type attribute is set to “radio”.  

Attention reader! Don’t stop learning now. Get hold of all the important HTML concepts with the Web Design for Beginners | HTML  course.


<input type="radio">  

Example: Below code illustrates that how to add a radio button in the webpage. 


<!DOCTYPE html>
        body {
            text-align: center;
        h2 {
            color: green;
        How to add a Radio Buttons in form using HTML?
    Select Gender
    <input type="radio" checked=true name="user_gender">
    <input type="radio"  name="user_gender">     


gender of user

My Personal Notes arrow_drop_up
Recommended Articles
Page :