On iOS 26, sliders now support tick marks with a TrackConfiguration. This configuration is used to set up the look and behavior for the slider.

Here we can take example to limit speed slider to only 5 values. Let see how to set the track configuration.
UISlider has a new property called trackConfiguration, by use of it we can now achieve the functionality – for which we have to install some third party libraries.
@IBOutlet weak var slider26: UISlider!
slider26.trackConfiguration = .init(allowsTickValuesOnly: true, neutralValue: 0.25, numberOfTicks: 5)

Here, we have used 3 parameters of trackConfiguration :
allowsTickValuesOnly– It’s a boolean which states we want user to select values in between the tick values or not.neutralValue– It’s a float value which defines the base value for slider. For Example, speed slider can haveneutralValue1.0 (i.e. 0.25 in respect of 0.0 to 1.0 value inUISlider)- numberOfTicks – It’s a integer to define the number of ticks on slider.
ticks– It’s nearly looking like undocumented stuff. but Ticks class has ability to define image and title with the tick mark. I have tried, but there is no result getting changed for now. Maybe in the next beta we will get an update for this. Let me show you in code.
@IBOutlet weak var slider26: UISlider!
let ticks: [UISlider.TrackConfiguration.Tick] = [
.init(position: 0, title: "0.25"),
.init(position: 0.25, title: "1.0"),
.init(position: 0.50, title: "1.25"),
.init(position: 0.75, title: "1.5"),
.init(position: 1, title: "2.0")
]
slider26.trackConfiguration = .init(allowsTickValuesOnly: true, neutralValue: 0.25, ticks: ticks)
Right now, even if I have passed ticks result is pretty similar like we pass numberOfTicks.
Conclusion
- Xcode 26 beta 2, iOS 26 beta 2 and other beta just released. I will explore and keep posted.
Let me know if you have any questions, comments, or feedback – via X (Twitter) or LinkedIn. Feel free to contact me and discuss what you are learning and developing.
Happy Coding 🙂