<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "CoreHID",
  "identifier" : "/documentation/CoreHID",
  "metadataVersion" : "0.1.0",
  "role" : "Framework",
  "symbol" : {
    "kind" : "Framework",
    "modules" : [
      "Core HID"
    ],
    "preciseIdentifier" : "CoreHID"
  },
  "title" : "Core HID"
}
-->

# Core HID

Interact with keyboards, mice, and other human interface devices.

## Overview

The CoreHID framework facilitates interaction with human interface devices (HID), like a keyboard, mouse, or other device. Interactions include receiving data that a device generates, such as a key press or mouse click. CoreHID also allows sending requests to a device, such as a request to turn on an LED. You can also emulate a device connected to the system, such as a virtual game controller, and send input to other apps without physical hardware.

![An image showing the Swift logo on the left. Three arrows emerge from it and point to the right. The first arrow points to a game controller. The second arrow points to a mouse. The third arrow points to a keyboard.](images/com.apple.CoreHID/core-hid-overview@2x.png)

To learn more about HID devices, see the [USB standards website](https://www.usb.org/hid).

## Topics

### Discovery

[Discovering HID devices from Terminal](/documentation/CoreHID/DiscoveringHIDDevicesFromTerminal)

Identify devices connected to your Mac from the command line.

[`HIDDeviceManager`](/documentation/CoreHID/HIDDeviceManager)

A helper for discovering human interface devices (HID) connected to the system.

[`HIDDeviceManager.DeviceMatchingCriteria`](/documentation/CoreHID/HIDDeviceManager/DeviceMatchingCriteria)

Matching criteria used to filter HID devices.

### Interaction

[Communicating with human interface devices](/documentation/CoreHID/CommunicatingWithHIDDevices)

Interact with and obtain data from devices such as keyboards and mice.

[`HIDDeviceClient`](/documentation/CoreHID/HIDDeviceClient)

A client of a physical or virtual HID compatible peripheral.

[`HIDElement`](/documentation/CoreHID/HIDElement)

A representation of an item from a report descriptor for a HID device.

[`HIDElementCollection`](/documentation/CoreHID/HIDElementCollection)

A collection of items from a report descriptor for a HID device.

[`HIDElement.Value`](/documentation/CoreHID/HIDElement/Value)

Data associated with a HID element.

[`HIDElementUpdate`](/documentation/CoreHID/HIDElementUpdate)

A base protocol for element update types.

[`HIDReportType`](/documentation/CoreHID/HIDReportType)

Types for HID reports.

[`HIDReportID`](/documentation/CoreHID/HIDReportID)

A type to represent the report IDs of HID reports.

[`HIDUsage`](/documentation/CoreHID/HIDUsage)

A type to represent HID usage pages.

[`HIDDeviceError`](/documentation/CoreHID/HIDDeviceError)

Errors that the framework can throw.

[`HIDDeviceTransport`](/documentation/CoreHID/HIDDeviceTransport)

Common transport types that transmit data to or from a HID device.

[`HIDDeviceLocalizationCode`](/documentation/CoreHID/HIDDeviceLocalizationCode)

The localization codes that some HID devices declare to specify conformance to a certain format or language.

### Simulation

[Creating virtual devices](/documentation/CoreHID/CreatingVirtualDevices)

Use and interact with a virtual human interface device for testing and development.

[`HIDVirtualDevice`](/documentation/CoreHID/HIDVirtualDevice)

A virtual service to emulate a HID device connected to the system.

[`HIDVirtualDeviceDelegate`](/documentation/CoreHID/HIDVirtualDeviceDelegate)

The delegate to receive notifications for a virtual HID device.

[`HIDVirtualDevice.Properties`](/documentation/CoreHID/HIDVirtualDevice/Properties)

The properties for a virtual HID device.



---

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)