<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: -",
    "macOS: 15.0.0 -",
    "visionOS: 26.0.0 -",
    "watchOS: 11.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "WidgetKit",
  "identifier" : "/documentation/WidgetKit/WidgetRelevanceAttribute/init(group:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "WidgetKit"
    ],
    "preciseIdentifier" : "s:9WidgetKit0A18RelevanceAttributeVAAytRszlE5groupACyytGAA0aC5GroupV_tcfc"
  },
  "title" : "init(group:)"
}
-->

# init(group:)

Associates the widget kind with a group. When multiple widgets are in
the same group, the system only suggests one member of the group
simultaneously. Widgets in the same group are interpreted to contain
redundant information, and therefore should not be presented together.

```
init(group: WidgetRelevanceGroup)
```

## Parameters

`group`

the group to associate the widget with

## Discussion

Multiple groups can be associated with the same widget by providing
multiple `WidgetRelevanceAttribute` instances with different
groups.

---

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)