<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "AppKit",
  "identifier" : "/documentation/AppKit/NSDocument/saveTo(_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AppKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSDocument(im)saveDocumentTo:"
  },
  "title" : "saveTo(_:)"
}
-->

# saveTo(_:)

The action method invoked in the receiver as first responder when the user chooses the Save To menu command.

```
@IBAction func saveTo(_ sender: Any?)
```

## Parameters

`sender`

The control sending the message.

## Discussion

The default implementation is identical to [`saveAs(_:)`](/documentation/AppKit/NSDocument/saveAs(_:)) except that this method doesn’t clear the document’s edited status and doesn’t reset file location and document type if the document is a native type.

---

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)