How Email Verification Really Works?

How To Create A Custom Email Validation Error Message

Despite being the most convenient form of communication over the web, emails attract a lot of notoriety. Dealing with spam and fake e-mail ids is the bane of any online user. The biggest question is: how does one validate email addresses? From an online marketing perspective, it is all about generating email validation error messages to improve the conversion rate of a marketing campaign. 

This post covers the best practices for handling e-mail validation along with developer techniques for building e-mail validation code on the server side. You are expected to have an intermediate level of familiarity with Node.js to understand the code snippets and examples presented here.

What is a Validation Error Message?

Online marketers rely on e-mail lists to target prospective customers. Automating the subscription opt-in process to weed out any invalid email address is an effective way to ensure the sanity of the list. But many times, checking for a valid email is a binary, yes or no decision, with a generic error message, such as “Invalid Email Address” displayed on the user interface.

What you need is a mechanism to validate email addresses objectively. This entails capturing the email address from the input field and checking it for the server configuration, SMTP status, roles, and disposability of an email address to classify it under various categories that define the probability of reaching the intended recipient.

Thankfully, all of this is possible with just an API call. The Abstract E mail Validation and Verification API gives you a comprehensive report so that you can validate various aspects of an email address to generate custom error messages for things such as:

  • Basic formatting: Checking for invalid email address format and recommending corrections for typos.
  • Non-personal categorization: Checking for role-based emails, such as, or catch-all email ids like not associated with a person.
  • Mail Server Configuration Validation: Checking for the SMTP server and MX record status to ensure that the emails are not handled by span services.
  • Quality Score: A quality score between 0.01 to 0.99, reflecting Abstract's confidence in the quality and deliverability of the submitted e-mail.

Error Message Best Practices

Error messages are the first source of information about something going amiss with an email address. Therefore, it is important to build a mechanism such that the messages are well articulated to aid the specific use case.

Here are some essential guidelines to write error messages that are instantly decipherable:

  1. Clear Text: For understanding technical jargon, clarity triumphs over complexity. A clear error message is easier to read than trying to figure out an error message loaded with complex technical terms, such as “SMTP Error” or “MX Record not found”.   
  2. Helpful Information: For a better user experience, it is good to provide helpful information in the error message to build empathy with the user. As an example, providing a recommendation for a typo in the email address would go a long way to build empathy, instead of showing a blunt “Email Address Not Found” error message.  
  3. Situation Specific Content: The error message should be customized to the error situation. For example, in case of a formatting issue, it is better to show that explicitly, rather than displaying something like “Invalid Email”.

Creating Custom Error Messages

Using Abstract’s E mail Validation and Verification API, you can plug in your e-mail validation logic with custom error messages. 

First, let’s test the API to get a sense of what it offers. Signup for a free account on Abstract and head over to the API dashboard.

Perform a live test of the API.

You should get a response from the API, containing several fields that validate the email address for various checks.

Considering a genuine email address, the complete API response in JSON formal looks somewhat like this.

    "email": "",
    "autocorrect": "",
    "deliverability": "DELIVERABLE",
    "quality_score": "0.99",
    "is_valid_format": {
        "value": true,
        "text": "TRUE"
    "is_free_email": {
        "value": false,
        "text": "FALSE"
    "is_disposable_email": {
        "value": false,
        "text": "FALSE"
    "is_role_email": {
        "value": false,
        "text": "FALSE"
    "is_catchall_email": {
        "value": true,
        "text": "TRUE"
    "is_mx_found": {
        "value": true,
        "text": "TRUE"
    "is_smtp_valid": {
        "value": true,
        "text": "TRUE"

You can see that the API checks the email address at syntax, semantic, and systemic levels. For instance, the field “is_valid_format” checks for the syntax of the email address. “is_role_email” checks for the semantic meaning of the email id. Similarly, “is_mx_found” checks for a valid MX record on the domain that hosts the email.

Keeping the best practices in mind, it is possible to build a custom validation logic based on a layered approach that performs the various syntax, semantics, and the systemic level validations of an email address.

Syntax Level

Syntax level checking ensures that the email address is formatted correctly, with the mandatory ‘@’ and ‘.’ characters and some minimum number of characters.

You can call the Abstract Email Validation and Verification API with the Axios HTTP client for Node.js and check for the format.

let response =  await axios.get('' + <YOUR_ABSTRACT_API_KEY> + '&’)

  throw new Error("Invalid Email Format")

Semantic Level

Semantic level checks decipher the email address to find out associations with a persona or type of e-mail service.

For example, if a website is collecting email addresses of readers who want to read a newsletter, then the website owner would want to validate the user input to ensure that the emails belong to an actual human, instead of some role or catchall e mail id. Also, the email addresses should belong to a well-known domain with good domain authority, instead of some temporary email service.

The API response returned by Abstract Email Validation and Verification API has specific flags to identify these categories.

let response =  await axios.get('' + <YOUR_ABSTRACT_API_KEY> + '&’)

if ( ||{
    throw new Error("Free/Disposable Email")
} else if ( ||{
    throw new Error("Generic (Role / Catchall) Email")

Systemic Level

Systemic level checks ensure that the e-mail server configuration records are valid. These are specific to the MX record and SMTP domain configuration settings.

let response =  await axios.get('' + <ABSTRACT_API_KEY> + '&’)

if (!{
    throw new Error("Invalid Email Record")
} else if (!{
    throw new Error("Invalid Email Id or Unknown Mail Server")

Creating Dynamic Error Messages

While it is good to have specific error messages for email addresses, it is possible to enhance the user experience by customizing the error message further.

For example, let’s assume your website has a subscription form with an input field that accepts email addresses from visitors who opt-in for your newsletter. On the server side, you can incorporate the Abstract Email Validation and Verification API. With a Node.js / Express.js-based stack, it is easy to add the e-mail validation using the express-validator library.

Here is how you can define an API endpoint ‘GET  /subscribe’ that performs a custom validation of e-mail to return specific error messages based on the response from Abstract Email Validation and Verification API.

const express = require('express')
const bodyParser = require('body-parser');
const axios = require('axios')
const app = express()
const { body, validationResult } = require('express-validator');
const port = 3000


//app.use(bodyParser.urlencoded({ extended: true }));

async function validationEmail(val, {req}){

  let response =  await axios.get('' + ABSTRACT_API_KEY + '&email=' + val)

    throw new Error("Invalid Email Format")
  } else if ( ||{
    throw new Error("Free/Disposable Email")
  } else if ( ||{
    throw new Error("Generic (Role / Catchall) Email")
  } else if (!{
    throw new Error("Invalid Email Record")
  } else if (!{
    throw new Error("Invalid Email Id or Unknown Mail Server")

  return true
         async (req, res) => {

          const errors = await validationResult(req);

          if (!errors.isEmpty()) {
            return res.status(400).json({ status: "fail", errors: errors.array() });
          console.log("Adding New Subscriber " + + " to Database")  
          return res.status(200).json({ status: "success", errors: "[]" });

Make a new Node.js project and install express, Axios, and express-validator libraries using the npm tool. Also, save the above code as the source file named app.js, and replace the placeholder <YOUR_ABSTRACT_API_KEY> with your Abstract API key.

Upon running this code, you can test the API with several invalid email addresses, to get the desired error message with the HTTP 400 error code. In the case of a valid email address, it returns a 200 OK response.

To make the error messages more dynamic, you can further analyze the Abstract Email Validation and Verification API response against an email address query to capture:

  1. Quality score: This provides an indicative probability of spam email addresses. Your error message can contain additional information that translates this quality score to a range of quality attributes for email addresses.
  2. Auto-Correction: This is a recommendation for the possible valid e-mail ids, in case the queried email address is invalid.
  3. Deliverability: This parameter checks whether the emails sent to the queried email address are deliverable or not. This can provide an additional warning to show if emails are not deliverable.

Validation Error Message FAQs

What Is a Validation Error Message?

A validation error message provides information about the validity of an email address. It can contain syntax, semantics, and system-related error messages to find out whether an email address is valid. With the help of Abstract Email Validation and Verification API, it is possible to perform various validation checks on an email address.

What does Email Validation Mean? 

Email validation is the process of validating the various aspects of an email address, from format to server and DNS-related configuration, and more. The Abstract Email Validation and Verification API can validate various aspects of an email address, such as its format, nature of the email service (free or disposable), type of email id (personal or role-based or catch-all), and more.

How Do You Add A Validation Error Message?

You can add validation error messages on the server side while accepting the email addresses as part of an API request. If using a Node.js/Express.js stack, you can wrap the Abstract Email Validation and Verification API as part of the express-validator library to build custom error messages in API responses.

Email Validation Tools and Services

There are tons of email validation tools and services in the market right now. All of them have different top features. Some validate one information, and some do other. Here are the top free email verification tools. 


It’s one of the most popular email verifying tools used by companies like TripAdvisor. ZeroBounce provides multiple verification processes. It does the single and bulk email validation and also provides you with crucial customer data. 

Pricing: ZeroBounce offers monthly 100 email validation for free. If you want to go for more, the pricing starts from $39 to $249 per month. You need to call them for pricing if you want everything unlimited.

Free Bulk Email Validator by H-Supertools

For using this tool, you need to create an H-Supertools account. You can verify 20 email addresses at one time and 200 email addresses per day. It’s worth it because it helps you do the bulk email validation without spending your fortune. 

Pricing: The tool is free forever and is supported by ads. 


It’s one of the most popular email validation tools in the market used by companies like Shopify. According to them, they’ve validated over 5 billion email addresses by now. It does seamless integration with third parties and different file formats. 

Pricing: Usually, EmailListVerify charges $0.004 per email address validation. But they roll out some significant discounts every month. So, don’t forget to check that out.  


Invalid email addresses bring in a bad reputation for your company or domain name. You’ll also waste a lot of time and resources in email marketing because of the high bounce rate. So the first thing you need to do after you collect some email addresses is validated them. 

The process of validating email addresses is called email validation. It involves checking the spellings, format, and syntax of your email contacts. And it also includes looking up the DNS or pinging the email box. 

I have already given the JavaScript and HTML code for email validation. But if you are a beginner, go for the top email validation tools or services. Validate your email addresses with Email Validator by H-Supertools if you don’t want to spend bucks. 

That’s it! Next time when someone wonders, “What is email validation?” Take charge and start explaining. Have questions? Let me know in the comments below. I’ll try my best to answer all of them. 

 The ROI of email marketing can be 122% or more without a doubt. But it’s possible only if you do it correctly. The foundation of any email marketing strategy is the email list, which should be clean and deliverable. The first thing you must do is email validation. But what is email validation? What are its benefits? And how to do it correctly?

I’ll help you answer all these questions in this post. You’ll get started with a bang in email marketing, even if you’re a beginner. So let’s get started right away. 

What is email validation?

So you made a great effort in collecting email addresses using different ways. And you sent an important email to the vast contact list. But you just came to know that most of the contacts were not even valid. Maybe some of them aren’t correctly formatted. 

The solution? Email validation, of course. It’s a process of verifying an email address to confirm its validity and existence. It also ensures if the email address is deliverable and has a reliable domain such as Gmail. But why must you do the email validation?

Why You Must Validate Email Addresses

Let’s suppose you have collected email addresses and run an email campaign without email validation. You’ll get hard bounces for invalid email addresses. And the existing email recipients will get their emails, right? Wrong! 

Hard bounces impair your sender’s reputation, and a poor reputation means decreased email deliverability. So even if some email addresses exist, you’ll not be able to deliver the email to their inboxes. And that may be a big problem for an entire email marketing team. 

what is email validation

These are some of the top reasons you must validate your email list:

  • Decrease hard bounces
  • Avoid risky email addresses
  • Improve primary inbox deliverability
  • Get to know the accurate marketing data
  • Boost your reputation
  • Get rid of spam complaints
  • Stop check-all and temporary accounts
  • Increase the engagement rates
  • Enjoy the low-cost email marketing

And the list goes on. Thankfully you don’t need to do the email validation continuously.

Do it only if:

  • You get new recipients added to your list
  • Your bounce rate increases
  • Or you get low open rates

But do it at least once a month, even if nothing terrible happens. Doing the email validation regularly ensures you have a clean deliverable email list. 

Now that you know the basics of email validation and why you must do it let’s understand how it works.

How Does Email Validation Work

Email verification and email validation are similar, but the former is more complex than the latter. Email validation consists of a process of improving your email deliverability. There are tons of ways of validating email addresses. 

But generally, you start with spell check; make sure you have not misspelled anything. And then hunt for spam traps. There are tons of email addresses created to capture senders who aren’t following the best emailing practices. 

ISPs (Internet Services Providers) and ESPs (Email Service Providers) make sure you don’t have those email addresses in your list. Or else they’ll block you. 

The next thing you’d like to do is check the format of your email addresses. Ensure you don’t miss any @ symbol in your email contacts. For example, email validation tools or services must catch if an email address is like mike@mike@dd. Do the syntax checking properly. 

Also, email validation works like individual mailbox validation. It uses the SMTP protocol to ensure if a mailbox exists for a particular address. 

Let me summarize and create an email validation checklist for you:

  • Check the spellings
  • Do the syntax validation
  • Hunt the disposable email addresses
  • Monitor the DNS behind the contact
  • Ping the email box

Email validation takes a second if it’s done correctly with software or a bunch of codes. There are tons of free and premium tools to validate your email list on the go.

However, you can do it manually, which may take a long time. And if you’re like me, you should dig deeper into the subject, especially if you’re a beginner.

How to Verify Email Addresses Without Sending Emails

An email address consists of an @ symbol, a dot, and ASCII characters. The first part has private information, and the second one has the domain name in which the email is registered. Let me get more detailed here.

The first part of the email address contains:

  • Uppercase and lowercase alphabets like A, b, c, and more. 
  • Special symbols like @, _, – or more. 
  • Full stop, dot, etc. 

And the second part of the email address contains:

  • Dots
  • Hyphens
  • Digits
  • Letters

These are the examples of valid email addresses:


While the examples of invalid email addresses include:

  • (consecutive dots aren’t allowed)
  • (no domain begins with a dot)
  • tony()$%^ (go for characters, underscore, dash, and digits only)
  • (there must be an @ symbol)
  • myname@abcd.e (.e is an invalid domain name)

What is Email Validation and How does it help you?

Email Deliverability Solutions - One Tool Is All You Need

Analyze & Monitor Email Deliverability-DMARC, Reputation Monitoring, Inbox Tracking & More. Are Your Emails Going To The Spam Folder? Having Trouble Reaching A Certain Domain? Analytics Dashboard. Blocklist Checker. Real-Time Alerts.

Email Checking Tool - Instant Writing Assistant

Grammarly's tone detector can help you convey the tone you intend in your emails. Eliminate Grammar Errors Instantly and Enhance Your Writing. Try Now For Free! Improve Word Choice. Eliminate Grammar Errors. Easily Improve Any Text. Find and Add Sources Fast.


Post a Comment