I tried to log in to iCloud for the first time on my older model Apple TV using the correct password with no success. I restarted, reset(restore), reset(reset all settings), verified the correct time-zone & region format and none of these problem resolution options worked for me that I read online. Finally I decided to try turning off the two-step verification process when Managing AppleID online and I was able to log into iCloud on my Apple TV. Prior to doing that I would receive a pop up alert on my phone indicating someone was trying login to a new device with my AppleID. After selecting allow it would generate a code indicating I should use it after entering my password. I would enter my password & then the code, enter the code first & then the password several times. That's when I suspected the two-step authentication is what was preventing me from logging in. Hope this was able to help you if you were experiencing the same problem.
Apple TV iCloud login failed/two-part authentication code/AppleID login alert
Site and App Feedback & HelpWelcome to iMore! I haven't run into this issue on either of my AppleTVs but I honestly haven't had to log in in a very long time. One possible solution would be to generate an app-specific password and use that, along with your Apple ID, as your login on AppleTV. That way you won't lose the extra security provided by two-step verification. To do that:
1. Go to http://applied.apple.com and log in.
2. Select PASSWORD AND SECURITY
3. Select GENERATE AN APP-SPECIFIC PASSWORD.
4. Use the generated code as your password on AppleTV.
1. Go to http://applied.apple.com and log in.
2. Select PASSWORD AND SECURITY
3. Select GENERATE AN APP-SPECIFIC PASSWORD.
4. Use the generated code as your password on AppleTV.
Wow - what a helpful answer! Thanks @DevilishBanker! Hopefully the OP (and others) can take advantage of this guide!
Original thread: https://forums.imore.com/threads/apple-tv-icloud-login-failed-two-part-authentication-code-appleid-login-alert.346860/