<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "Xcode: 14.2.0 -",
    "watchOS: 8.0.0 -"
  ],
  "documentType" : "article",
  "framework" : "HealthKit",
  "identifier" : "/documentation/HealthKit/build-a-workout-app-for-apple-watch",
  "metadataVersion" : "0.1.0",
  "role" : "sampleCode",
  "title" : "Build a workout app for Apple Watch"
}
-->

# Build a workout app for Apple Watch

Create your own workout app, quickly and easily, with HealthKit and SwiftUI.

## Overview

> Note: This sample code project is associated with WWDC21 session
> [10009: Build a workout app for Apple Watch](https://developer.apple.com/wwdc21/10009/).

### Configure the sample code project

Before you run the sample code project in Xcode:

1. Open the sample with the latest version of Xcode.
2. Select the top-level project.
3. For the three targets, select the correct team in the Signing & Capabilities pane (next to Team) to let Xcode automatically manage your provisioning profile.
4. Make a note of the Bundle Identifier of the WatchKit App target.
5. Open the `Info.plist` file of the WatchKit Extension target, and change the value of the `NSExtension` > `NSExtensionAttributes` > `WKAppBundleIdentifier` key to the bundle ID you noted in the previous step.
6. Make a clean build and run the sample app on your device.

---

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)