Title: Filter to extend the 2FA code validity?
Last modified: June 6, 2025

---

# Filter to extend the 2FA code validity?

 *  Resolved [crdunst](https://wordpress.org/support/users/crdunst/)
 * (@crdunst)
 * [1 year ago](https://wordpress.org/support/topic/filter-to-extend-the-2fa-code-validity/)
 * Hi guys, we have your plugin installed on a site, but unfortunately the site 
   users’ email provider is slow at processing/scanning emails inbound to the site
   user’s inbox. The upshot is that the 2FA code (by email) triggers and sends perfectly,
   but by the time they receive the code, it’s expired. 
   Is there a filter to extend
   the validity of the 2FA codes?Thanks in advance.

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

 *  Plugin Support [kmarusek](https://wordpress.org/support/users/kmarusek/)
 * (@kmarusek)
 * [11 months, 3 weeks ago](https://wordpress.org/support/topic/filter-to-extend-the-2fa-code-validity/#post-18521291)
 * Hi there,
 * Thanks for reaching out!
 * Currently, there isn’t a filter or setting available to extend the expiration
   time of 2FA email codes. If the emails are arriving too late to be usable, it
   likely points to a delay on the mail server or email provider’s side.
 * You might want to look into your SMTP service or contact your email provider 
   to check for delays or throttling. Alternatively, we recommend switching to a
   more reliable method like mobile-based 2FA (using an authenticator app), which
   doesn’t depend on email delivery and tends to be faster and more secure.
 * Let me know if you need help switching 2FA methods. Be sure to follow the document
   on 2FA here:
   [https://solidwp.com/documentation/security/how-it-works/solid-security-two-factor-authentication-2fa-settings-guide/](https://solidwp.com/documentation/security/how-it-works/solid-security-two-factor-authentication-2fa-settings-guide/)
   Best,KevinSolidWP Support
 *  Thread Starter [crdunst](https://wordpress.org/support/users/crdunst/)
 * (@crdunst)
 * [11 months, 3 weeks ago](https://wordpress.org/support/topic/filter-to-extend-the-2fa-code-validity/#post-18521301)
 * Hi Kevin, thanks for following up.
 * Yes the 2FA code generation, and our SMTP delivery worked perfectly. It was the
   recipients mail server holding them for spam checking. We just wondered if there
   was a workaround by extending the code time period.
 * It’s fine though, we spoke with their mail provider and they’re whitelisting 
   the sending domain, so they get them straightaway now.
 * Thanks again, I’ll close this ticket.

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

The topic ‘Filter to extend the 2FA code validity?’ is closed to new replies.

 * ![](https://ps.w.org/better-wp-security/assets/icon.svg?rev=3529351)
 * [Kadence Security – Password, Two Factor Authentication, and Brute Force Protection](https://wordpress.org/plugins/better-wp-security/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/better-wp-security/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/better-wp-security/)
 * [Active Topics](https://wordpress.org/support/plugin/better-wp-security/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/better-wp-security/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/better-wp-security/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [crdunst](https://wordpress.org/support/users/crdunst/)
 * Last activity: [11 months, 3 weeks ago](https://wordpress.org/support/topic/filter-to-extend-the-2fa-code-validity/#post-18521301)
 * Status: resolved