<!--
{
  "availability" : [

  ],
  "documentType" : "symbol",
  "framework" : "ExceptionHandling",
  "identifier" : "/documentation/ExceptionHandling",
  "metadataVersion" : "0.1.0",
  "role" : "Framework",
  "symbol" : {
    "kind" : "Framework",
    "modules" : [
      "Exception Handling"
    ],
    "preciseIdentifier" : "ExceptionHandling"
  },
  "title" : "Exception Handling"
}
-->

# Exception Handling

Monitor and debug exceptional conditions in code.

## Overview

This collection of documents provides the API reference for the Exception Handling
framework. This framework provides facilities for monitoring and debugging exceptional
conditions in Objective-C code.

Currently only one class reference is part of this collection: the reference for
the [`NSExceptionHandler`](/documentation/ExceptionHandling/NSExceptionHandler) class, which is defined in `NSExceptionHandler.h`.

## Topics

### Classes

[`NSExceptionHandler`](/documentation/ExceptionHandling/NSExceptionHandler)

The `NSExceptionHandler` class provides facilities for monitoring and debugging exceptional
conditions in Objective-C programs. It works by installing a special uncaught exception
handler via the  <doc://com.apple.documentation/documentation/Foundation/NSSetUncaughtExceptionHandler(_:)>
function. Consequently, to use the services of `NSExceptionHandler`, you must not
install your own custom uncaught exception handler.

### Protocols

[NSExceptionHandlerDelegate](/documentation/ExceptionHandling/nsexceptionhandlerdelegate)

The `NSExceptionHandlerDelegate` informal protocol describes methods that [`NSExceptionHandler`](/documentation/ExceptionHandling/NSExceptionHandler)
objects call on their delegates when exceptions occur. An [`NSExceptionHandler`](/documentation/ExceptionHandling/NSExceptionHandler)
object does not need to have a delegate. When one does, these delegate methods are
asked to approve exception handling and logging for each monitored [`NSExceptionHandler`](/documentation/ExceptionHandling/NSExceptionHandler)
object.

### Reference

[ExceptionHandling Enumerations](/documentation/ExceptionHandling/exceptionhandling-enumerations)

[ExceptionHandling Constants](/documentation/ExceptionHandling/exceptionhandling-constants)

[ExceptionHandling Functions](/documentation/ExceptionHandling/exceptionhandling-functions)



---

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)
