I guess you are thinking about double opt-in emails. I mean sending confirmation emails to eliminate the invalid one. But it has two problems: 1) you still need to send an email to an invalid address to find out this is invalid. It can affect your sending reputation is a long term. 2) How do you want to fight with disposable emails then?
This is why checking an email syntax using or sending a double opt-in confirmation email is not enough. You need to check if an email address exists before you want to store it to your database or send it a confirmation email. DeBounce offers a robust email validation API that offers real-time email validation and verification. You can implement the API in your backend and perform proper actions if the email address is valid.
As you can see, if an invalid email is provided, the email address will be converted to a placeholder (which is equal to an empty input), so if the email field is a mandatory one, the form cannot submit. To set up this type of email validation, you need to have a DeBounce account with an API key. This is a paid service, but we did our best to lower the validation prices. You can open an account here and get an API key from here. Note that you must copy the public API key because it can be detected by all users that are seeing your page. You also must add your domain address to the approved CORS domains of your API key. This means only approved addresses can use the validation widget and it will not work on other websites. Once you have a valid public API key with proper permissions, this is time to put the codes to your HTML page – after the form or at the end of the page: