# 2fa security key breaks when migrating to custom domain

**URL:** https://meta.discourse.org/t/2fa-security-key-breaks-when-migrating-to-custom-domain/155528
**Category:** Bug
**Created:** [June 22, 2020, 8:11am UTC](https://meta.discourse.org/t/2fa-security-key-breaks-when-migrating-to-custom-domain/155528 "2020-06-22T08:11:36Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![Benjamin\_D](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/benjamin_d/32/277831_2.png) [@Benjamin\_D](https://meta.discourse.org/u/Benjamin_D)
#### Post date: [June 22, 2020, 8:20am UTC](https://meta.discourse.org/t/2fa-security-key-breaks-when-migrating-to-custom-domain/155528/2 "2020-06-22T08:20:25Z")

</div>

maybe you could try this:

> [@Oops, I lost my phone. How can I OTP now?](https://meta.discourse.org/t/oops-i-lost-my-phone-how-can-i-otp-now/143899/5):
>
> Search “disable 2fa” first result says So: ./launcher enter app rails c id = User.find\_by(username: "YOURUSERNAME").id UserSecondFactor.totps.where(user\_id: id).each(&:destroy!)

---

_[View the full topic](https://meta.discourse.org/t/2fa-security-key-breaks-when-migrating-to-custom-domain/155528)._
