# IRPCUsersAdmin.RemoveUser

Location: [gRPC API](https://developer.m-files.com/APIs/gRPC-API/index.md) > [Administration API](https://developer.m-files.com/APIs/gRPC-API/admin/index.md) > [Users](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/index.md)

HTML version: https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/RemoveUser/

Badges: `Administration API / specialized` `admin` `session`

Removes a user account from the vault.

- **Service:** [Users](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/index.md) `MFiles.IRPCUsersAdmin`
- **gRPC method:** `/MFiles.IRPCUsersAdmin/RemoveUser`
- **HTTP (mf-http-grpc):** `POST /grpc/v1/remove-user`
- **Request:** [`RemoveUserRequest`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/RemoveUser/index.md#request)
- **Response:** [`RemoveUserResponse`](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/RemoveUser/index.md#response)
- **Book and level:** Administration API, specialized
- **Kind:** admin
- **Session:** Required: the session ID from LogIn in the mfiles-session-id-bin metadata.
- **Idempotent:** no
- **Returns metadata structure version:** no
- **Streaming:** none (unary)

<a id="remarks"></a>

## Remarks

- Removes the account and its private data: its views, notification rules, event subscriptions
  and group memberships are deleted. Requires the vault rights `manage_users` and
  `license_allows_modifications`; removing an account with the `full_control` role also requires
  `change_full_control_role`.
- The user stays in the Users value list (6) as a deleted item, so objects that refer to the
  user keep the reference. Bring the account back with
  [AddUser](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/AddUser/index.md) (`USER_ACCOUNT_ADDITION_MODE_UNDELETE_OR_ADD`)
  or [UndeleteUserByGUID](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/UndeleteUserByGUID/index.md); the deleted views
  and rules do not come back.
- The login account is not removed.
- An account with an `external_id` can fail with "Access denied" ("... should be deleted via
  Manage").

<a id="request"></a>

## Request: RemoveUserRequest

> Nested message fields are expanded to depth 3; follow a type link for deeper levels and for the type's own page.

| Field | Type | Description |
|---|---|---|
| `id` | `int32` | The ID of the user account to remove. |

<a id="response"></a>

## Response: RemoveUserResponse

No fields.

<a id="related"></a>

## Related methods

- [AddUser](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/AddUser/index.md): Adds a user account to the vault, or brings back a removed one.
- [UndeleteUserByGUID](https://developer.m-files.com/APIs/gRPC-API/Reference/MFiles.IRPCUsersAdmin/UndeleteUserByGUID/index.md): Brings back a removed user account, identified by its GUID in the Users value list.
