<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "WebKit",
  "identifier" : "/documentation/WebKit/WKUIDelegate/webView(_:showLockdownModeFirstUseMessage:completionHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "WebKit"
    ],
    "preciseIdentifier" : "c:objc(pl)WKUIDelegate(im)webView:showLockdownModeFirstUseMessage:completionHandler:"
  },
  "title" : "webView(_:showLockdownModeFirstUseMessage:completionHandler:)"
}
-->

# webView(_:showLockdownModeFirstUseMessage:completionHandler:)

Displays a custom Lockdown Mode first use message.

```
optional func webView(_ webView: WKWebView, showLockdownModeFirstUseMessage message: String, completionHandler: @escaping @MainActor @Sendable (WKDialogResult) -> Void)
```

## Parameters

`webView`

The web view that is requesting to display the Lockdown Mode first use dialog.

`message`

The message for the web view to display if the delegate does not display the first use dialog.

`completionHandler`

A block you must invoke to resume after the web view displays the first use dialog. The block does not return a value, and accepts the following parameter:

- dialogResult: A display result case that indicates how the method handled the display request.

## Discussion

Implement this method to display a custom Lockdown Mode message, or to suppress the message. Return, or call the completion handler, with a [`WKDialogResult`](/documentation/WebKit/WKDialogResult) case that indicates how your method handled the display request. For more information about Lockdown Mode, see [About Lockdown Mode](https://support.apple.com/en-us/HT212650).

If you don’t implement this method, the web view displays the default message.

---

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)