<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "iPadOS: 13.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 13.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 6.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIImage/configuration-swift.property",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIImage(py)configuration"
  },
  "title" : "configuration"
}
-->

# configuration

The configuration details for the image.

```
@NSCopying var configuration: UIImage.Configuration? { get }
```

## Discussion

Use this property to access the traits associated with the image. The system uses the specified traits to determine which variant of the image to load and draw, falling back on the current environment for any unspecified traits. The default value of this property is a configuration object with unspecified traits.

You can’t modify this property directly, but you can use the [`withConfiguration(_:)`](/documentation/UIKit/UIImage/withConfiguration(_:)) method to create a new image object with a specific set of traits. You might do so when you want to render the image yourself using a specific set of traits.

If the image is a symbol image, this property always contains a [`UIImage.SymbolConfiguration`](/documentation/UIKit/UIImage/SymbolConfiguration-swift.class) object.

---

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)