<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "macOS: 13.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 7.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SwiftUI",
  "identifier" : "/documentation/SwiftUI/Gauge/init(value:in:label:currentValueLabel:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "SwiftUI"
    ],
    "preciseIdentifier" : "s:7SwiftUI5GaugeV5value2in5label17currentValueLabelACyxq_AA9EmptyViewVAIGqd___SNyqd__GxyXEq_yXEtcAIRs0_AIRs1_SBRd__lufc"
  },
  "title" : "init(value:in:label:currentValueLabel:)"
}
-->

# init(value:in:label:currentValueLabel:)

Creates a gauge showing a value within a range and that describes the
gauge’s purpose and current value.

```
nonisolated init<V>(value: V, in bounds: ClosedRange<V> = 0...1, @ContentBuilder label: () -> Label, @ContentBuilder currentValueLabel: () -> CurrentValueLabel) where BoundsLabel == EmptyView, MarkedValueLabels == EmptyView, V : BinaryFloatingPoint
```

## Parameters

`value`

The value to show on the gauge.

`bounds`

The range of the valid values. Defaults to `0...1`.

`label`

A view that describes the purpose of the gauge.

`currentValueLabel`

A view that describes the current value of
the gauge.

## Discussion

Use this method to create a gauge that displays a value within a range
you supply with labels that describe the purpose of the gauge and its
current value. In the example below, a gauge using the
[`circular`](/documentation/SwiftUI/GaugeStyle/circular) style shows its current value of `67` along with a
label describing the (BPM) for the gauge:

```
struct SimpleGauge: View {
    @State private var current = 67.0

    var body: some View {
        Gauge(value: current, in: 0...170) {
            Text("BPM")
        } currentValueLabel: {
            Text("\(current)")
        }
        .gaugeStyle(.circular)
   }
}
```

![A screenshot showing a circular gauge describing heart rate in beats](images/com.apple.SwiftUI/SwiftUI-Gauge-LabelCurrentValueCircular@2x.png)

---

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)