Django: SMTPRecipientsRefused: Sender address rejected: not owned by user
I have a Django app running on a server with uWSGI and nginx.
In my local_settings.py
file I have this:
###############
# EMAIL SETUP #
###############
EMAIL_HOST = 'smtp.privateemail.com'
EMAIL_HOST_USER = 'support@mydomain.com'
EMAIL_HOST_PASSWORD = 'MY EMAIL PASSWORD'
EMAIL_PORT = 465
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_USE_TLS = True
########################
# OTHER EMAIL SETTINGS #
########################
ADMIN_EMAIL = "admin@mydomain.com"
SUPPORT_EMAIL = "support@mydomain.com"
DEFAULT_FROM_EMAIL = ADMIN_EMAIL
SERVER_EMAIL = ADMIN_EMAIL
I run python manage.py runserver
on my local machine in the Django project's virtual environment. I fill out the password reset form at password_rest/
using the email my.personal@gmail.com
and submit it. I get this error.
SMTPRecipientsRefused: {u'my.personal@gmail.com': (553, '5.7.1 <admin@mydomain.com>: Sender address rejected: not owned by user support@mydomain.com')}
My website's email provider is Namecheap.
Why do I get this error when testing on my local machine? What must I change/add to get rid of it? How do authenticate my website's mail service?
2 Replies
Are you using email forwarding with Namecheap?
Can I Send Emails From My Personalized Email Address Using Your Email Forwarding
I changed EMAIL_HOST
to 'mail.privateemail.com'
. Email successfully sends when using my local machine. But not on Linode server. I'll make a new thread for the new problem.