---
title: layer
framework: uikit
role: symbol
role_heading: Instance Property
path: uikit/uiview/layer
---

# layer

The view’s Core Animation layer to use for rendering.

## Declaration

```swift
var layer: CALayer { get }
```

## Discussion

Discussion This property is never nil. The value of the layerClass property determines the actual class of the layer object. The view is the layer’s delegate. warning: Because the view is the layer’s delegate, never make the view the delegate of another CALayer object. Additionally, never change the delegate of this layer object.

## See Also

### Configuring a view’s visual appearance

- [backgroundColor](uikit/uiview/backgroundcolor.md)
- [isHidden](uikit/uiview/ishidden.md)
- [alpha](uikit/uiview/alpha.md)
- [isOpaque](uikit/uiview/isopaque.md)
- [tintColor](uikit/uiview/tintcolor.md)
- [tintAdjustmentMode](uikit/uiview/tintadjustmentmode-swift.property.md)
- [clipsToBounds](uikit/uiview/clipstobounds.md)
- [clearsContextBeforeDrawing](uikit/uiview/clearscontextbeforedrawing.md)
- [mask](uikit/uiview/mask.md)
- [layerClass](uikit/uiview/layerclass.md)
