How to ping an email address to check its validity

Last updated: February 11, 2021
Matthew

If you need to check if an email address is valid, without sending an actual email, here's how you can do it for free. Don't forget there are more reliable, faster, and easier methods, especially if you need to check hundreds or thousands of emails. Check out the best bulk email verifications services.

How to ping an email address on windows (7,8 & 10)

1. Enable Telnet

Use the search bar to look for "Turn Windows features on or off". Alternatively, you can go to control panel, programs, features, where you will find the same option.

Open the "Turn Windows features on or off".
In the Windows Features window, make sure to enable (check) the Telnet Client and click OK.

2. Open the command prompt (CMD)

Search for "cmd" using the search bar and open the command prompt.

3. Find the mailserver the domain you want to check

Enter the following command into the command prompt window, replace "gmail.com" with the domain of the email you want to check and press enter.

windownslookup –type=mx gmail.com

The command prompt now shows you a list of MX-records for the domain:

Non-authoritative answer:
gmail.com MX preference = 20, mail exchanger = alt2.gmail-smtp-in.l.google.com
gmail.com MX preference = 40, mail exchanger = alt4.gmail-smtp-in.l.google.com
gmail.com MX preference = 5, mail exchanger = gmail-smtp-in.l.google.com
gmail.com MX preference = 30, mail exchanger = alt3.gmail-smtp-in.l.google.com
gmail.com MX preference = 10, mail exchanger = alt1.gmail-smtp-in.l.google.com

4. Opening connection to the server

Pick one of the servers, for this example, we'll pick the gmail-smtp-in.l.google.com. We'll now open the connection with the server:

telnet gmail-smtp-in.l.google.com 25

You will now receive an answer similar to this:

220 mx.google.com ESMTP t15si801824edw.542 - gsmtp

You've just opened a connection to the server.

5. Talking to the server

We'll now use a sequence of SMTP commands to talk to the email server.

Let's start by presenting yourself using command "HELO", and specify a domain of your choice. You'll act as if you're about to send an email from that domain.

HELO randomdomain.com

Here's the answer you'll receive:

250 mx.google.com at your service

Great! The server is at our service.

Next, let's tell the server who's about to send the email. Again, choose a random ID under the previously used domain.

MAIL FROM:<[email protected]>

The answer will be similar to this:

250 2.1.0 OK dd24si970465ejb.523 - gsmtp

Finally we are getting to actually testing if the email account exists. Use the RCPT TO command together with the email you want to test.

RCPT TO:<[email protected]>

Here's our answer! This email account doesn't exist:

550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1 https://support.google.com/mail/?p=NoSuchUser h20si903055eja.402 - gsmtp

If the email address exists, the answer would be similar to this:

250 2.1.5 OK c10si876593edj.155 - gsmtp

That's it, you can close the connection by typing "quit".

Whole telnet command sequence

Here's the whole "chat" with the email server after connection is established, our commands in bold.

220 mx.google.com ESMTP a14si944935ejj.581 - gsmtp
HELO randomdomain.com
250 mx.google.com at your service
MAIL FROM:<[email protected]>
250 2.1.0 OK a14si944935ejj.581 - gsmtp
RCPT TO:<[email protected]>
550-5.1.1 The email account that you tried to reach does not exist. Please try
550-5.1.1 double-checking the recipient's email address for typos or
550-5.1.1 unnecessary spaces. Learn more at
550 5.1.1 https://support.google.com/mail/?p=NoSuchUser a14si944935ejj.581 - gsmtp

Leave a Reply

Your email address will not be published. Required fields are marked *