customised checkBox package for swiftUI

What's New

First Release


In this release general functionalities are included, such as adding checkbox with title, changing checkbox color, changing checkbox title color.


CheckBox-SwiftUI is a custom checkbox package for SwiftUI. It provides a simple and customizable checkbox view that is missing in the native SwiftUI framework. The package utilizes SF Symbols to represent the checkbox states and offers options to customize the checkbox appearance.

If you like the project, please do not forget to star ★ this repository and follow me on GitHub.


preview of checkbox


  • iOS 13.0+
  • Xcode 11.2+
  • Swift 5.0
  • SwiftUI framework


  • Customizable checkbox view for SwiftUI.
  • Uses SF Symbols for checkbox states.
  • Supports toggling the checkbox state.
  • Optional customization of checkbox color and title color.


Swift Package Manager

You can add CheckBox-SwiftUI as a dependency in your Swift Package Manager-enabled project. Follow these steps to integrate the package into your project:

  1. In Xcode, go to "File" -> "Add Packages...".
  2. Enter the URL of this repository:
  3. Choose the desired version rule.
  4. Chosse the target where you want to add the package.
  5. Click "Add Package".
  6. Wait till Xcode varify and fetch it for you.
  7. Click "Add Package".


To use CheckBox-SwiftUI in your SwiftUI project, follow these steps:

  1. Import the CheckBoxSwiftUI module:
import CheckBoxSwiftUI
  1. Create a @State property to hold the checkbox state:
@State private var isChecked = false
  1. Use the 'CheckBox' view in your SwiftUI view hierarchy:
CheckBox(isChecked: $isChecked, title: "Click on this checkbox")
  1. Customize the checkbox appearance by providing optional parameters:
CheckBox(isChecked: $isChecked, title: "Checkbox", checkBoxColor: .blue, titleColor: .black)

Integration into a complete but simple code:

import SwiftUI
import CheckBoxSwiftUI

struct ContentView: View {
@State private var isChecked = false

    var body: some View {
        VStack {
            CheckBox(isChecked: $isChecked, title: "Click on this checkbox")


Md. Mahinur Rahman, iOS Developer

Find Me on:

FaceBook Instagram LinkedIn Twitter Website Discord


Contributions to CheckBox-SwiftUI are welcome! If you encounter any issues or have ideas for improvements, please feel free to open an issue or submit a pull request.


Please feel free to open any issue


CheckBox-SwiftUI is available under the MIT License. See the LICENSE file for more information.


  • Swift Tools 5.8.0
View More Packages from this Author


  • None
Last updated: Thu Mar 14 2024 16:30:57 GMT-0900 (Hawaii-Aleutian Daylight Time)