> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XUserState

> XUserState

# XUserState

Specifies the current state of the user.

## Syntax

```cpp theme={null}
enum class XUserState  : uint32_t  
{  
    SignedIn = 0,  
    SigningOut = 1,  
    SignedOut = 2,  
}  
```

## Constants

| Constant   | Description              |
| ---------- | ------------------------ |
| SignedIn   | The user is signed in.   |
| SigningOut | The user is signing out. |
| SignedOut  | The user is signed out.  |

## Remarks

To get the state of a given user, call the [XUserGetState](/reference/system/xuser/functions/xusergetstate) function. The function accepts a pointer to an XUserState enumeration as an argument.

To monitor changes in the state of a user, subscribe to [XUserChangeEvent](/reference/system/xuser/enums/xuserchangeevent) by calling [XUserRegisterForChangeEvent](/reference/system/xuser/functions/xuserregisterforchangeevent).

## Requirements

**Header:** XUser.h

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## See also

[XUser](/reference/system/xuser/xuser_members)

[XUserChangeEvent](/reference/system/xuser/enums/xuserchangeevent)

[XUserRegisterForChangeEvent](/reference/system/xuser/functions/xuserregisterforchangeevent)


## Related topics

- [XUserGetState](/reference/system/xuser/functions/xusergetstate.md)
- [User identity and XUser](/build/core-features/common/user/player-identity-xuser.md)
- [XUser](/reference/system/xuser/xuser_members.md)
- [XblPresenceUserState](/reference/live/xsapi-c/presence_c/enums/xblpresenceuserstate.md)
- [XR-052 User state, title-save location, and roaming](/publishing/certification/xr/xr-052.md)
