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

# 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](https://docs.xbox.com/reference/system/xuser/functions/xusergetstate.md) 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](https://docs.xbox.com/reference/system/xuser/enums/xuserchangeevent.md) by calling [XUserRegisterForChangeEvent](https://docs.xbox.com/reference/system/xuser/functions/xuserregisterforchangeevent.md).

## Requirements

**Header:** XUser.h

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

## See also

[XUser](https://docs.xbox.com/reference/system/xuser/xuser_members.md)

[XUserChangeEvent](https://docs.xbox.com/reference/system/xuser/enums/xuserchangeevent.md)

[XUserRegisterForChangeEvent](https://docs.xbox.com/reference/system/xuser/functions/xuserregisterforchangeevent.md)


## Related topics

- [User identity and XUser](https://docs.xbox.com/build/core-features/common/user/player-identity-xuser.md)
- [XUserGetState](https://docs.xbox.com/reference/system/xuser/functions/xusergetstate.md)
- [XUser (API contents)](https://docs.xbox.com/reference/system/xuser/xuser_members.md)
- [XblPresenceUserState](https://docs.xbox.com/reference/live/xsapi-c/presence_c/enums/xblpresenceuserstate.md)
- [PartyRemoveLocalUserCompletedStateChange](https://docs.xbox.com/services/playfab/multiplayer/networking/reference/structs/partyremovelocalusercompletedstatechange.md)
