Title: Not Receiving Email with Authentication Code
Last modified: July 12, 2020

---

# Not Receiving Email with Authentication Code

 *  Resolved [nevrsmer](https://wordpress.org/support/users/nevrsmer/)
 * (@nevrsmer)
 * [5 years, 11 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/)
 * Hi,
 * For some reason, I am not receiving the email with the authentication code. The
   email listed in Users > Two-Factor Options is correct. The email option is also
   enable and is set as Primary.
 * The emails are not arriving in the inbox or going to the spam folder. I’ve requested
   the email be resent on the login page, but it never arrives.
 * The TOTF factor, however, does work.
 * What are your suggestions to get the email option to work?
 * Thanks!

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Plugin Author [Kaspars](https://wordpress.org/support/users/kasparsd/)
 * (@kasparsd)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-13198872)
 * Thanks for reporting the issue! This is usually caused by the receiving email
   client marking the authentication code emails as spam due to the sending web 
   server configuration such as [missing SPF records](https://support.google.com/a/answer/33786?hl=en).
 * The plugin is using the exact same email delivery mechanism as WP core so it 
   should arrive similar to password reset emails, etc.
 *  [John Brown](https://wordpress.org/support/users/kitchenproduct/)
 * (@kitchenproduct)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-13445733)
 * Hi,
 * I just installed the plugin and tried to log in to my account, but I’m not getting
   any code in my mail. (I have checked the spam folder but didn’t get anything)
   
   The email listed in Users> Two-Factor Options is correct. The email option is
   also enabled and is set as Primary. I have been waiting for 1 hour and still 
   didn’t receive any code in my mail.
 * Please help me getting the code as I’m not able to login to my website. Or, if
   you could uninstall the plugin, it would be great.
 * Please help me, I’m so depressed right now 🙁
 * Thanks in advance
    -  This reply was modified 5 years, 8 months ago by [John Brown](https://wordpress.org/support/users/kitchenproduct/).
 *  Thread Starter [nevrsmer](https://wordpress.org/support/users/nevrsmer/)
 * (@nevrsmer)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-13445942)
 * John,
 * I could never resolve the issue of not receiving the codes by email despite having
   them sent to various emails addresses, so it was not an issue with the “receiving
   email client marking the authentication code email as spam” as Kaspars indicated.
   The email simply never arrived to any account, not even as spam. With that said,
   choose a different verification option.
 * As for not being able to log in to your account, if you have access to your server,
   go to: public_html > wp-content > Plugins, and rename the folder Two Factor (
   or whatever it is named to something else ). You can just add a letter to it 
   to keep it simple when returning it to its original name. That will allow you
   to log in to the WP Dashboard. Once there, you can change the verification method,
   after returning the name of the plugin to its original name so that it works 
   again.
 * If you don’t have access to your server, contact your host’s tech support and
   they can do it. If you don’t feel you can do it, have them do it either way. 
   It’s really easy. It’s nothing more than changing a file name on an operating
   system on your computer.
 * Also, make a copy of the temporary, one-time-use passcodes the plugin generate
   just in case.
 * Hope this helps!
 *  [rockstervivek](https://wordpress.org/support/users/rockstervivek/)
 * (@rockstervivek)
 * [5 years, 7 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-13565890)
 * Plugin is working fine.
 * You need to do some steps before getting a mail.
 * 1. You need SMTP server to send mail. You can install (WP SMTP) plugin and configure
   it from this doc [https://www.wpbeginner.com/plugins/how-to-set-up-wp-mail-smtp-with-any-host-ultimate-guide/](https://www.wpbeginner.com/plugins/how-to-set-up-wp-mail-smtp-with-any-host-ultimate-guide/)
 * After that select email verification and bingo you are good to go.
 * I did above steps and its working fine.
 *  [Vladimir Vassilev](https://wordpress.org/support/users/vloo/)
 * (@vloo)
 * [5 years, 3 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-14103388)
 * I’m facing a similar problem with the emails with code not being sent. An easy
   test to make sure that WordPress is generally sending emails and that they don’t
   end up in spam is by attempting to reset one’s password through the “Lost password”
   form. This test works for me. Yet, once I set the right username and password
   in login page, I am left on the verification code page without actually receiving
   anything neither in inbox, nor in spam.
 * I’ve checked the logs after setting WP_DEBUG and WP_DEBUG_LOG to true => no result
   whatsoever.
 * My environment is WP 5.5.3, the plugin is v.0.7.0, PHP is at v.7.2.34.
 * I’m not sure that marking the issue as resolved was the right thing to do if 
   even it’s author had to stop using the email method and went for an alternative.
 *  [wordpresser](https://wordpress.org/support/users/mohammedays/)
 * (@mohammedays)
 * [4 years, 11 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-14603971)
 * thank you for pining the topic
 *  [ddur](https://wordpress.org/support/users/ddur/)
 * (@ddur)
 * [4 years, 10 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-14673460)
 * > As for not being able to log in to your account, if you have access to your
   > server, go to: public_html > wp-content > Plugins, and rename the folder Two
   > Factor (or whatever it is named to something else ). You can just add a letter
   > to it to keep it simple when returning it to its original name.
 * I usually add . (dot) as first character in order to hide plugin directory and
   prevent it to appear again renamed and deactivated on plugins page.
 * /two-factor/ -> /.two-factor/

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Not Receiving Email with Authentication Code’ is closed to new replies.

 * ![](https://ps.w.org/two-factor/assets/icon.svg?rev=2887448)
 * [Two Factor](https://wordpress.org/plugins/two-factor/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/two-factor/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/two-factor/)
 * [Active Topics](https://wordpress.org/support/plugin/two-factor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/two-factor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/two-factor/reviews/)

 * 7 replies
 * 7 participants
 * Last reply from: [ddur](https://wordpress.org/support/users/ddur/)
 * Last activity: [4 years, 10 months ago](https://wordpress.org/support/topic/not-receiving-email-with-authentication-code/#post-14673460)
 * Status: resolved