Admin Locked out by 2FA with Notification-Login

I unfortunately activated 2FA with notification on my admin account (without backup codes or alternative method). Unfortunately I had the browser in incognito mode.

When I try to login, Nextcloud now tells me to confirm the notification with my other instance - which I had closed but is still active for Nextcloud.

Did I screw up and exclude myself? Can I close the “active” session of the old login somehow? It won’t be closed automatically if you don’t log out properly… Or is there anything else I can do to log back in as admin?

This is what I found here:

https://docs.nextcloud.com/server/15/admin_manual/configuration_user/two_factor-auth.html

Should users lose access to their second factor and backup codes, they won’t be able to log into their account anymore. As administrator, you can use the Two-Factor Admin Support app to generate a one-time code for them to log in and unlock their account. You can find out more about the app in its documentation

Found another option. Maybe this works for you AS well?:

1 Like

You can disable 2FA using occ, as well as create new users. You need shell access to run it.