<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.10.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Social",
  "identifier" : "/documentation/Social/SLComposeServiceViewController/isContentValid()",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Social"
    ],
    "preciseIdentifier" : "c:objc(cs)SLComposeServiceViewController(im)isContentValid"
  },
  "title" : "isContentValid()"
}
-->

# isContentValid()

A Boolean value that indicates whether the current content and attachments are valid.

```
func isContentValid() -> Bool
```

## Return Value

<doc://com.apple.documentation/documentation/Swift/true> if the current content and attachments are valid for posting, otherwise <doc://com.apple.documentation/documentation/Swift/false>. The default return value is <doc://com.apple.documentation/documentation/Swift/true>.

## Discussion

This method is automatically called after each change a user makes to the text in the compose view. You can use this method to determine whether the Post button should be enabled and to update [`charactersRemaining`](/documentation/Social/SLComposeServiceViewController/charactersRemaining), if necessary.

A subclass should implement this method to perform custom validation of the user’s content before initiating a post.

---

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)