If you can't sign out due to restrictions, or your Apple Account is grayed out in Settings
If you're unable to sign out of your Apple Account, or your Apple Account is grayed out in Settings on your iPhone or iPad, check if you have a Screen Time passcode and/or Screen Time restrictions enabled.
If you can't sign out due to restrictions
If you can't sign out of your Apple Account on your iPhone or iPad because you see "Sign out is not available due to restrictions", you might have a Screen Time passcode enabled. Check for a Screen Time passcode, then turn it off to sign out of your Apple Account.
Turn off your Screen Time passcode
Open the Settings app, then tap Screen Time.
Scroll down, then tap Change Screen Time Passcode.
Tap Turn Off Screen Time Passcode, then enter your passcode to turn it off.
Learn what to do if you forgot your Screen Time passcode
If your Apple Account is grayed out in the Settings app
If your Apple Account is grayed out in the Settings app, you might have certain Screen Time restrictions enabled for your device.
Check your Screen Time settings
Open the Settings app, then tap Screen Time.
Tap Content & Privacy Restrictions.
If Content & Privacy Restrictions is turned on, scroll down to the Allow Changes To section.
Tap Accounts, and set it to Allow. If asked, enter your Screen Time passcode.
Then from the same screen, check if any other settings are set to Don't Allow. If so, tap the setting, then choose Allow. If asked, enter your Screen Time passcode.

If you're a child or teen in a Family Sharing group
If you're a child in a Family Sharing group and your parent or guardian set up parental controls to manage your device, you need to ask them to enter their Screen Time passcode to allow changes to your device settings. Changes to a child's Screen Time passcode must be made on the parent or guardian's device.
Need more help?
Tell us more about what's happening, and we’ll suggest what you can do next.