<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIColorPickerViewController",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIColorPickerViewController"
  },
  "title" : "UIColorPickerViewController"
}
-->

# UIColorPickerViewController

A view controller that manages the interface for selecting a color.

```
@MainActor class UIColorPickerViewController
```

## Overview

[`UIColorPickerViewController`](/documentation/UIKit/UIColorPickerViewController) provides a standard interface to select colors. Use this class instead of [`UIColorWell`](/documentation/UIKit/UIColorWell) if you need more fine-grained control over the presentation.

![Screenshot of a color picker in a popover presentation style, showing a spectrum of color options. The title of the color picker is Colors.](images/com.apple.uikit/media-4195196@2x.png)

You typically present a [`UIColorPickerViewController`](/documentation/UIKit/UIColorPickerViewController) as a popover:

```swift
// This example code appears in a subclass of UIViewController that conforms to
// UIColorPickerViewControllerDelegate.
func presentColorPicker() {
    let colorPicker = UIColorPickerViewController()
    colorPicker.title = "Background Color"
    colorPicker.supportsAlpha = false
    colorPicker.delegate = self
    colorPicker.modalPresentationStyle = .popover
    colorPicker.popoverPresentationController?.sourceItem = self.navigationItem.rightBarButtonItem
    self.present(colorPicker, animated: true)
}
```

You can also react to the color-selection change or the dismissal of the color picker by implementing the [`UIColorPickerViewControllerDelegate`](/documentation/UIKit/UIColorPickerViewControllerDelegate) functions.

## Topics

### Creating a color picker view controller

[`-  init`](/documentation/UIKit/UIColorPickerViewController/init())

Creates a color picker view controller.

### Configuring the color picker view controller

[`delegate`](/documentation/UIKit/UIColorPickerViewController/delegate)

The delegate that receives updates about the color selection.

[`UIColorPickerViewControllerDelegate`](/documentation/UIKit/UIColorPickerViewControllerDelegate)

The delegate protocol to inform about changes in color selection.

[`maximumLinearExposure`](/documentation/UIKit/UIColorPickerViewController/maximumLinearExposure)

The maximum exposure to apply to a color when returned by the color picker.

[`selectedColor`](/documentation/UIKit/UIColorPickerViewController/selectedColor)

The color selected by the user.

[`supportsAlpha`](/documentation/UIKit/UIColorPickerViewController/supportsAlpha)

A Boolean value that enables alpha value control.

[`supportsEyedropper`](/documentation/UIKit/UIColorPickerViewController/supportsEyedropper)

If set to `NO` the eyedropper functionality is not supported for this color picker.

## Relationships

### Conforms To

[`UIUserActivityRestoring`](/documentation/UIKit/UIUserActivityRestoring)

[`NSTouchBarProvider`](/documentation/AppKit/NSTouchBarProvider)

[`UITraitEnvironment`](/documentation/UIKit/UITraitEnvironment)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

[`Sendable`](/documentation/Swift/Sendable)

[`UIActivityItemsConfigurationProviding`](/documentation/UIKit/UIActivityItemsConfigurationProviding)

[`UIAppearanceContainer`](/documentation/UIKit/UIAppearanceContainer)

[`NSExtensionRequestHandling`](/documentation/Foundation/NSExtensionRequestHandling)

[`UITraitChangeObservable-67e94`](/documentation/UIKit/UITraitChangeObservable-67e94)

[`NSCoding`](/documentation/Foundation/NSCoding)

[`CVarArg`](/documentation/Swift/CVarArg)

[`UIContentContainer`](/documentation/UIKit/UIContentContainer)

[`UIStateRestoring`](/documentation/UIKit/UIStateRestoring)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`UIFocusEnvironment`](/documentation/UIKit/UIFocusEnvironment)

[`Hashable`](/documentation/Swift/Hashable)

[`Equatable`](/documentation/Swift/Equatable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`UIResponderStandardEditActions`](/documentation/UIKit/UIResponderStandardEditActions)

[`UIPasteConfigurationSupporting`](/documentation/UIKit/UIPasteConfigurationSupporting)

### Inherits From

[`UIViewController`](/documentation/UIKit/UIViewController)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)