---
title: userInfo
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/nsexception/userinfo-swift.property
---

# userInfo

A dictionary containing application-specific data pertaining to the receiver.

## Declaration

```swift
var userInfo: [AnyHashable : Any]? { get }
```

## Discussion

Discussion nil if no application-specific data exists. As an example, if a method’s return value caused the exception to be raised, the return value might be available to the exception handler through this method.

## See Also

### Related Documentation

- [init(name:reason:userInfo:)](foundation/nsexception/init(name:reason:userinfo:).md)

### Querying an NSException Object

- [name](foundation/nsexception/name-swift.property.md)
- [reason](foundation/nsexception/reason-swift.property.md)
