Simple Python SMTP server for development ※
※
Aug 17
As developers we need a local SMTP server on our machines to test web applications while developing. Standard Python library includes a built-in SMTP server for debugging purposes that is ideal for our needs:
$ python -m smtpd -n -c DebuggingServer localhost:1025
Configure your web application to send email to localhost port 1025, and you will see email messages printed out to the terminal window.
If you use Django framework, add two lines to settings.py file of your project:
EMAIL_HOST = 'localhost' EMAIL_PORT = 1025
Good luck.