Language

Input Type Email


Input type="email" specifies that if the input element is not empty, it must contain a single valid email address.


The string that the user gives in the input element, that string must be in an email format. This string must contain an '@'. There will be some string before and after this '@'. However, there will be no whitespace in this format.

The method of input type email address validation is explained

Example

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <form>
        <label for="userEmail">Email Address</label>
        <input type="email"  id="userEmail">
        <input type="submit" value="Submit">
    </form>
</body>
</html>