<!--
{
  "availability" : [
    "iOS: 4.0.0 - 27.0.0",
    "iPadOS: 4.0.0 - 27.0.0",
    "macCatalyst: 13.1.0 - 27.0.0",
    "macOS: 10.7.0 - 27.0.0",
    "tvOS: 9.0.0 - 27.0.0",
    "visionOS: 1.0.0 - 27.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "AVFoundation",
  "identifier" : "/documentation/AVFoundation/AVAssetExportSession/cancelExport()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AVFoundation"
    ],
    "preciseIdentifier" : "c:objc(cs)AVAssetExportSession(im)cancelExport"
  },
  "title" : "cancelExport()"
}
-->

# cancelExport()

Cancels the execution of an export session.

```
func cancelExport()
```

## Discussion

Apple discourages the use of this symbol. Use <doc://com.apple.documentation/documentation/Swift/Task/cancel()> on the <doc://com.apple.documentation/documentation/Swift/Task> or parent task that initiated the export instead.

---

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)