title: How to correctly configure Django to send emails with Gmail and what are the correct settings for the Gmail account?
body: <p>I would appreciate some help with setting up Gmail with a Django application.
  I am trying to send send an email using gmail through Django to reset user passwords.
  My settings.py SMTP configuration is:</p>
  <pre><code>EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
  EMAIL_HOST = 'smtp.gmail.com'
  EMAIL_PORT = 587
  EMAIL_USE_TLS = True
  EMAIL_HOST_USER = 'myemail@gmail.com'
  EMAIL_HOST_PASWORD = 'mypassword'
  </code></pre>
  <p>For the password I tried using both, the actual account password and the generated 16 digit password for apps which don't support 2-step authentication. I enabled the IMAP access and access for less secure apps in my gmail settings. I am still getting this error when trying to reset the password on my Django app:</p>
  <blockquote>
  <p>SMTPSenderRefused at /reset/
  (530, b'5.7.0 Authentication Required. Learn more at\n5.7.0  <a href="https://support.google.com/mail/?p=WantAuthError" rel="nofollow noreferrer">https://support.google.com/mail/?p=WantAuthError</a> s21sm6387949wmc.10 - gsmtp', 'webmaster@localhost')</p>
  </blockquote>
  <p>Any ideas what am I doing wrong? I am not sure if this is an issue with my configuration in Django or Gmail settings. Thanks in advance.</p>