---
title: failureResponse
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/urlauthenticationchallenge/failureresponse
---

# failureResponse

The URL response object representing the last authentication failure.

## Declaration

```swift
@NSCopying var failureResponse: URLResponse? { get }
```

## Discussion

Discussion This value is nil if the protocol doesn’t use responses to indicate an authentication failure.

## See Also

### Related Documentation

- [error](foundation/urlauthenticationchallenge/error.md)

### Getting properties of previous authentication attempts

- [previousFailureCount](foundation/urlauthenticationchallenge/previousfailurecount.md)
- [proposedCredential](foundation/urlauthenticationchallenge/proposedcredential.md)
