Click here to Skip to main content
Click here to Skip to main content

How to send a test email message using Telnet

, 28 Feb 2011 CPOL
Rate this:
Please Sign up or sign in to vote.
How to send a test email message using Telnet
Occasionally I’ve had to troubleshoot sending email messages to a particular SMTP server by simulating a mail client (or .NET mail code) by using the telnet client. Here’s how I do it on Windows:
  1. Open the command prompt
  2. type: telnet 25 <press enter>
  3. type: helo <press enter>
  4. type: mail from: <press enter>
  5. type: rcpt to: <press enter>
  6. type: data <press enter>
  7. Write a test message. Typically, I type something like: hello world! <press enter>
  8. To send the message, type a single period (.) on a line by itself and of course, press enter


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Pete Mourfield
Software Developer (Senior)
United States United States
Software Developer
Follow on   Twitter   Google+

Comments and Discussions

Generalhow could i provide user name and password. I am trying this... Pinmembercode in play1-Mar-11 19:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.141216.1 | Last Updated 28 Feb 2011
Article Copyright 2011 by Pete Mourfield
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid