<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SpriteKit",
  "identifier" : "/documentation/SpriteKit/SKView/allowsTransparency",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "SpriteKit"
    ],
    "preciseIdentifier" : "c:objc(cs)SKView(py)allowsTransparency"
  },
  "title" : "allowsTransparency"
}
-->

# allowsTransparency

A Boolean property that indicates whether the view is rendered using transparency.

```
var allowsTransparency: Bool { get set }
```

## Discussion

This property tells the drawing system as to how it should treat the view. If set to <doc://com.apple.documentation/documentation/Swift/false>, the drawing system treats the view as fully opaque, which allows the drawing system to optimize some drawing operations and improve performance. If set to <doc://com.apple.documentation/documentation/Swift/true>, the drawing system composites the view normally with other content. The default value of this property is <doc://com.apple.documentation/documentation/Swift/false>.

An opaque view is expected to fill its bounds with entirely opaque content—that is, the content should have an alpha value of 1.0. If the view is opaque and either does not fill its bounds or contains wholly or partially transparent content, the results are unpredictable. Always set the value of this property to <doc://com.apple.documentation/documentation/Swift/false> if the view is fully or partially transparent.

---

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)