<!--
{
  "availability" : [
    "iOS: 10.0.0 -",
    "iPadOS: 10.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 10.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIGraphicsPDFRendererContext/addDestination(withName:at:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIGraphicsPDFRendererContext(im)addDestinationWithName:atPoint:"
  },
  "title" : "addDestination(withName:at:)"
}
-->

# addDestination(withName:at:)

Creates a named destination point in the current PDF page.

```
func addDestination(withName name: String, at point: CGPoint)
```

## Parameters

`name`

The name of the destination, used as a reference by the [`setDestinationWithName(_:for:)`](/documentation/UIKit/UIGraphicsPDFRendererContext/setDestinationWithName(_:for:)) method.

`point`

The location of the destination point, in the PDF coordinate space.

## Discussion

Use this method in conjunction with the [`setDestinationWithName(_:for:)`](/documentation/UIKit/UIGraphicsPDFRendererContext/setDestinationWithName(_:for:)) method to create internal links within a PDF. This method represents the creation of the points to which the PDF viewer will jump when a user clicks a link.

> Note:
> Specify the `point` value in the PDF coordinate space, not the Core Graphics context coordinate space. This means that the origin is in the bottom-left corner of the context rather than the top-left, and the y-axis increases in an upwards direction. Use the <doc://com.apple.documentation/documentation/CoreGraphics/CGContext/userSpaceToDeviceSpaceTransform> property on <doc://com.apple.documentation/documentation/CoreGraphics/CGContext> to map between the two.

For an example of how to use internal links, including mapping between coordinate spaces, see  [`Creating internal links`](/documentation/UIKit/UIGraphicsPDFRenderer#Creating-internal-links) in [`UIGraphicsPDFRenderer`](/documentation/UIKit/UIGraphicsPDFRenderer).

---

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)