How to check if a Email address exist or not using the command line

  • In this example we will test for the Email address [email protected], replace the gmail Email address with the email address you want to test
  • Open the command line/command promt and type in the following command
    nslookup -type=mx

    This command will list the MX records of the gmail domain eg.

    Non-authoritative answer:
    mail exchanger = 5
    mail exchanger = 10
    mail exchanger = 20
    mail exchanger = 30
    mail exchanger = 40
    Authoritative answers can be found from:
    internet address =
    internet address =
    internet address =
    internet address =
    internet address =
  • Select one of the servers listed in the list of MX records and pretend to send a message to that server from your local machine
    • Connect to the server via telnet
      telnet 25
    • Type in the HELO command
    • Identify yourself using any email address eg. [email protected]
      mail from:<[email protected]>
    • Type in the email address that you wish to verify
  • After the last command entered, the server will respond with a message whether the email address exist/is valid or not e.g.
    250 2.1.5 OK o15si4900954fal.31 //For success


    The email account that you tried to reach does not exist. //Failure

Image Credits: Photo by Isis França on Unsplash.

More Similar Posts

No results found.