<!--
{
  "availability" : [
    "iOS: 9.0.0 -",
    "iPadOS: 9.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "GameplayKit",
  "identifier" : "/documentation/GameplayKit/GKGridGraph/node(atGridPosition:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "GameplayKit"
    ],
    "preciseIdentifier" : "c:objc(cs)GKGridGraph(im)nodeAtGridPosition:"
  },
  "title" : "node(atGridPosition:)"
}
-->

# node(atGridPosition:)

Returns the node in the graph at the specified grid coordinates.

```
func node(atGridPosition position: vector_int2) -> NodeType?
```

## Parameters

`position`

The grid location to query.

## Return Value

The grid node at the specified location, or `nil` if there is no node at that location.

## Discussion

This method finds nodes that are part of the grid created by the graph. You can attach other nodes to the graph (for example, to represent the positions of game entities in the grid) with the [`connectToAdjacentNodes(node:)`](/documentation/GameplayKit/GKGridGraph/connectToAdjacentNodes(node:)) method, but such nodes are not part of the grid itself.

---

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)