<!--
{
  "availability" : [
    "macOS: 10.1.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SystemConfiguration",
  "identifier" : "/documentation/SystemConfiguration/SCDynamicStoreCopyLocalHostName(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "System Configuration"
    ],
    "preciseIdentifier" : "c:@F@SCDynamicStoreCopyLocalHostName"
  },
  "title" : "SCDynamicStoreCopyLocalHostName(_:)"
}
-->

# SCDynamicStoreCopyLocalHostName(_:)

Returns the current local host name.

```
func SCDynamicStoreCopyLocalHostName(_ store: SCDynamicStore?) -> CFString?
```

## Parameters

`store`

The dynamic store session that should be used for communication with the server. Pass `NULL` to use a temporary session.

## Return Value

Returns the current local host name, or `NULL` if the name has not been set or if an error occurred. You must release the return value.

## Discussion

---

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)