<!--
{
  "availability" : [
    "iOS: 14.0.0 -",
    "iPadOS: 14.0.0 -",
    "macCatalyst: -",
    "macOS: 11.0.0 -",
    "tvOS: 14.0.0 -",
    "visionOS: -",
    "watchOS: 7.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "os",
  "identifier" : "/documentation/os/Logger/init(subsystem:category:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "os"
    ],
    "preciseIdentifier" : "s:2os6LoggerV9subsystem8categoryACSS_SStcfc"
  },
  "title" : "init(subsystem:category:)"
}
-->

# init(subsystem:category:)

Creates a logger using the specified subsystem and category.

```
init(subsystem: String, category: String)
```

## Parameters

`subsystem`

The string that identifies the subsystem that emits signposts. Typically, you use the same value as your app’s *bundle ID*. For more information, see <doc://com.apple.documentation/documentation/BundleResources/Information-Property-List/CFBundleIdentifier>.

`category`

The string that the system uses to categorize emitted signposts.

---

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)