MAIL_SERVER = 'smtp.gmail.com' MAIL_PORT = 465 MAIL_USE_SSL = True MAIL_USERNAME = 'username@gmail.com' MAIL_PASSWORD = 'app password generated in step 3'