The required attribute works with the following input types. text, search, url, tel, email, password, date pickers, number, checkbox, radio, and file.