<!--
{
  "availability" : [
    "iOS: 4.0.0 -",
    "iPadOS: 4.0.0 -",
    "macCatalyst: 13.1.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MessageUI",
  "identifier" : "/documentation/MessageUI/MFMessageComposeViewController/messageComposeDelegate",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Message UI"
    ],
    "preciseIdentifier" : "c:objc(cs)MFMessageComposeViewController(py)messageComposeDelegate"
  },
  "title" : "messageComposeDelegate"
}
-->

# messageComposeDelegate

The delegate to which message-related notifications should be sent.

```
weak var messageComposeDelegate: (any MFMessageComposeViewControllerDelegate)? { get set }
```

## Discussion

When the user taps a button to send or cancel the message, your delegate is notified and should respond by dismissing the message composition interface. For more information about implementing the methods of your delegate object, see [`MFMessageComposeViewControllerDelegate`](/documentation/MessageUI/MFMessageComposeViewControllerDelegate).

---

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)