Swiftpack.co -  HamzaGhazouani/HGCircularSlider as Swift Package
Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
A custom reusable circular / progress slider control for iOS application.
.package(url: "https://github.com/HamzaGhazouani/HGCircularSlider.git", from: "2.2.1")


Backers on Open Collective Sponsors on Open Collective Twitter: @GhazouaniHamza CI Status Version License Language Platform Carthage compatible

codebeat badge Documentation Readme Score


To run the example project, clone the repo, and run pod install from the Example directory first.

You also may like

  • HGPlaceholders - Nice library to show placeholders for any UITableView in your project
  • HGRippleRadarView - A beautiful radar view to show nearby users with ripple animation, fully customizable


  • iOS 9.0+
  • Xcode 11.4


HGCircularSlider is also available through Swift Package Manager

Follow this doc.

HGCircularSlider is also available through CocoaPods. To install it, simply add the following line to your Podfile:

pod 'HGCircularSlider', '~> 2.2.1'

HGCircularSlider is also available through Carthage. To install it, simply add the following line to your Cartfile:

github "HamzaGhazouani/HGCircularSlider"


  1. Change the class of a view from UIView to CircularSlider, RangeCircularSlider or MidPointCircularSlider
  2. Programmatically:
let circularSlider = CircularSlider(frame: myFrame)
circularSlider.minimumValue = 0.0
circularSlider.maximumValue = 1.0
circularSlider.endPointValue = 0.2


let circularSlider = RangeCircularSlider(frame: myFrame)
circularSlider.startThumbImage = UIImage(named: "Bedtime")
circularSlider.endThumbImage = UIImage(named: "Wake")

let dayInSeconds = 24 * 60 * 60
circularSlider.maximumValue = CGFloat(dayInSeconds)

circularSlider.startPointValue = 1 * 60 * 60
circularSlider.endPointValue = 8 * 60 * 60
circularSlider.numberOfRounds = 2 // Two rotations for full 24h range


let circularSlider = MidPointCircularSlider(frame: myFrame)
circularSlider.minimumValue = 0.0
circularSlider.maximumValue = 10.0
circularSlider.distance = 1.0
circularSlider.midPointValue = 5.0
If you would like to use it like a progress view
let progressView = CircularSlider(frame: myFrame)
progressView.minimumValue = 0.0
progressView.maximumValue = 1.0
progressView.endPointValue = 0.2 // the progress 
progressView.userInteractionEnabled = false 
// to remove padding, for more details see issue #25
progressView.thumbLineWidth = 0.0
progressView.thumbRadius = 0.0


Full documentation is available on CocoaDocs.
You can also install documentation locally using jazzy.


The UI examples of the demo project inspired from Dribbble.


The project is Inspired by UICircularSlider


Hamza Ghazouani, hamza.ghazouani@gmail.com


HGCircularSlider is available under the MIT license. See the LICENSE file for more info.


Stars: 2164
Last commit: 1 week ago

Ad: Job Offers

iOS Software Engineer @ Perry Street Software
Perry Street Software is Jack’d and SCRUFF. We are two of the world’s largest gay, bi, trans and queer social dating apps on iOS and Android. Our brands reach more than 20 million members worldwide so members can connect, meet and express themselves on a platform that prioritizes privacy and security. We invest heavily into SwiftUI and using Swift Packages to modularize the codebase.

Release Notes

Support SwiftPackageManager
1 year ago

Adding the support of SPM #62, thanks @TwoDollarsEsq

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API