---
title: backgroundColor
framework: uikit
role: symbol
role_heading: Instance Property
path: uikit/uibackgroundconfiguration-swift.struct/backgroundcolor
---

# backgroundColor

The color of the background.

## Declaration

```swift
var backgroundColor: UIColor? { get set }
```

## Discussion

Discussion If the value is nil, the background color is the view’s tint color. Use clear for a transparent background with no color.

## See Also

### Customizing the background

- [customView](uikit/uibackgroundconfiguration-swift.struct/customview.md)
- [cornerRadius](uikit/uibackgroundconfiguration-swift.struct/cornerradius.md)
- [backgroundInsets](uikit/uibackgroundconfiguration-swift.struct/backgroundinsets.md)
- [edgesAddingLayoutMarginsToBackgroundInsets](uikit/uibackgroundconfiguration-swift.struct/edgesaddinglayoutmarginstobackgroundinsets.md)
- [backgroundColorTransformer](uikit/uibackgroundconfiguration-swift.struct/backgroundcolortransformer.md)
- [resolvedBackgroundColor(for:)](uikit/uibackgroundconfiguration-swift.struct/resolvedbackgroundcolor(for:).md)
- [visualEffect](uikit/uibackgroundconfiguration-swift.struct/visualeffect.md)
- [shadowProperties](uikit/uibackgroundconfiguration-swift.struct/shadowproperties.md)
- [UIShadowProperties](uikit/uishadowproperties-swift.struct.md)
- [strokeColor](uikit/uibackgroundconfiguration-swift.struct/strokecolor.md)
- [strokeColorTransformer](uikit/uibackgroundconfiguration-swift.struct/strokecolortransformer.md)
- [resolvedStrokeColor(for:)](uikit/uibackgroundconfiguration-swift.struct/resolvedstrokecolor(for:).md)
- [strokeWidth](uikit/uibackgroundconfiguration-swift.struct/strokewidth.md)
- [strokeOutset](uikit/uibackgroundconfiguration-swift.struct/strokeoutset.md)
- [image](uikit/uibackgroundconfiguration-swift.struct/image.md)
