---
title: sexualActivity
framework: healthkit
role: symbol
role_heading: Type Property
path: healthkit/hkcategorytypeidentifier/sexualactivity
---

# sexualActivity

A category sample type that records sexual activity.

## Declaration

```swift
static let sexualActivity: HKCategoryTypeIdentifier
```

## Discussion

Discussion Use a HKCategoryValue.notApplicable value with these samples. These samples can include HKMetadataKeySexualActivityProtectionUsed metadata.

## Topics

### Metadata Keys

- [HKMetadataKeySexualActivityProtectionUsed](healthkit/hkmetadatakeysexualactivityprotectionused.md)

## See Also

### Related Documentation

- [HKCategoryValue](healthkit/hkcategoryvalue.md)
- [HKCategoryTypeIdentifier](healthkit/hkcategorytypeidentifier.md)
- [HKCategoryType](healthkit/hkcategorytype.md)
- [HKCategorySample](healthkit/hkcategorysample.md)

### Reproductive health

- [menstrualFlow](healthkit/hkcategorytypeidentifier/menstrualflow.md)
- [intermenstrualBleeding](healthkit/hkcategorytypeidentifier/intermenstrualbleeding.md)
- [infrequentMenstrualCycles](healthkit/hkcategorytypeidentifier/infrequentmenstrualcycles.md)
- [irregularMenstrualCycles](healthkit/hkcategorytypeidentifier/irregularmenstrualcycles.md)
- [persistentIntermenstrualBleeding](healthkit/hkcategorytypeidentifier/persistentintermenstrualbleeding.md)
- [prolongedMenstrualPeriods](healthkit/hkcategorytypeidentifier/prolongedmenstrualperiods.md)
- [basalBodyTemperature](healthkit/hkquantitytypeidentifier/basalbodytemperature.md)
- [cervicalMucusQuality](healthkit/hkcategorytypeidentifier/cervicalmucusquality.md)
- [ovulationTestResult](healthkit/hkcategorytypeidentifier/ovulationtestresult.md)
- [progesteroneTestResult](healthkit/hkcategorytypeidentifier/progesteronetestresult.md)
- [contraceptive](healthkit/hkcategorytypeidentifier/contraceptive.md)
- [pregnancy](healthkit/hkcategorytypeidentifier/pregnancy.md)
- [pregnancyTestResult](healthkit/hkcategorytypeidentifier/pregnancytestresult.md)
- [lactation](healthkit/hkcategorytypeidentifier/lactation.md)
- [HKCategoryValueVaginalBleeding](healthkit/hkcategoryvaluevaginalbleeding.md)
