<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 11.0.0 -",
    "tvOS: 17.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "NetworkExtension",
  "identifier" : "/documentation/NetworkExtension/NEDNSSettings/dnsProtocol",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Network Extension"
    ],
    "preciseIdentifier" : "c:objc(cs)NEDNSSettings(py)dnsProtocol"
  },
  "title" : "dnsProtocol"
}
-->

# dnsProtocol

The DNS protocol used by the server, such as HTTPS or TLS.

```
var dnsProtocol: NEDNSProtocol { get }
```

## Discussion

By default, an [`NEDNSSettings`](/documentation/NetworkExtension/NEDNSSettings) object will use [`NEDNSProtocol.cleartext`](/documentation/NetworkExtension/NEDNSProtocol/cleartext). In order to use encryption, create an [`NEDNSOverHTTPSSettings`](/documentation/NetworkExtension/NEDNSOverHTTPSSettings) or [`NEDNSOverTLSSettings`](/documentation/NetworkExtension/NEDNSOverTLSSettings) 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)