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

# rectForRow(at:)

Returns the drawing area for a row that an index path identifies.

```
func rectForRow(at indexPath: IndexPath) -> CGRect
```

## Parameters

`indexPath`

An index path object that identifies a row by its index and its section index.

## Return Value

A rectangle defining the area in which the table view draws the row or <doc://com.apple.documentation/documentation/CoreGraphics/CGRectZero> if `indexPath` is invalid.

---

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)