# Update a user preference

Launch stage: Beta

`PATCH /api/2.1/accounts/{account_id}/users/{user_id}/settings/{name}`

Update a user preference for a specific user.
 User preferences are personal settings that allow individual customization without affecting other users.
 See `settingsv2/listaccountuserpreferencesmetadata` for list of user preferences available via public APIs.

 Note: Page refresh is required for changes to take effect in UI.

API scopes: settings

## Path parameters

- `account_id` (string, uuid, required)
  Databricks account ID of the account being managed.
- `user_id` (string, required)
  User ID of the user whose setting is being updated.
- `name` (string, required)

## Request body

- `name` (string, optional)
  Name of the setting.
- `user_id` (string, optional)
  User ID of the user.
- `boolean_val` (object, optional)
  - `value` (boolean, optional)
- `string_val` (object, optional)
  - `value` (string, optional)
    Represents a generic string value.

## Returns

Returns the UserPreference object.

## Response

```json
{
  "name": "string",
  "user_id": "string",
  "boolean_val": {
    "value": true
  },
  "string_val": {
    "value": "string"
  },
  "effective_boolean_val": {
    "value": true
  },
  "effective_string_val": {
    "value": "string"
  }
}
```

