<!--
{
  "availability" : [
    "DriverKit: -",
    "iOS: -",
    "iPadOS: -",
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "DriverKit",
  "identifier" : "/documentation/DriverKit/IOService/NewUserClient",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "DriverKit"
    ],
    "preciseIdentifier" : "c:@S@IOService@F@NewUserClient#i#**$@S@IOUserClient#"
  },
  "title" : "NewUserClient"
}
-->

# NewUserClient

Requests the creation of a new user client for the service.

```
virtual kern_return_t NewUserClient(uint32_t type, IOUserClient **userClient);
```

## Parameters

`type`

The type passed to <doc://com.apple.documentation/documentation/iokit/1514515-ioserviceopen>.

`userClient`

A pointer to a variable for returning the new user client object. Upon the successful creation of the user client object, assign it to this variable.

## Return Value

[`kIOReturnSuccess`](/documentation/DriverKit/kIOReturnSuccess) on success, or another value if an error occurs. For a list of error codes, see [Error Codes](/documentation/DriverKit/error-codes).

## Discussion

Override this method if your service supports communication though an external user client. When an app calls <doc://com.apple.documentation/documentation/iokit/1514515-ioserviceopen> to start a new service, the system calls this method on the service passed to that function. In your implementation, call the [`Create`](/documentation/DriverKit/IOService/Create) method to create a new [`IOUserClient`](/documentation/DriverKit/IOUserClient) object for your service and return that object in the `userClient` parameter.

---

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)