Thanks, that is good to know. I wish there was something as easy as the iTunes backup for iPhones. There are Android apps that claim to do a more thorough job but I haven't tried them.
Titanium backup for a rooted device works great. If you have access to recovery you can also do a Nandroid backup which gives you 100% restore capability.
For non rooted this seems very tricky, that's why I asked. Most likely you will spend hours getting your phone to work again.
Notably, if you use google authenticator for 2FA, it won't backup and you'll restore a device that will no longer work as your second factor.