There are various ways how to handle this. Usually we suggest to have more than one device registered with the service/website. So worst-case you can still use the other device to log in. Many services also offer different other methods to handle such a situation: recovery codes, phone-based 2-factor, "forgot my password"-mechanisms or TOTPs. Please check which are supported for your service and make sure you have at least one additional option (I personally prefer two more).
Fill in the blank.