<!--
{
  "availability" : [
    "iOS: 7.0.0 -",
    "iPadOS: 7.0.0 -",
    "macCatalyst: 13.1.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UITableViewDelegate/tableView(_:estimatedHeightForHeaderInSection:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(pl)UITableViewDelegate(im)tableView:estimatedHeightForHeaderInSection:"
  },
  "title" : "tableView(_:estimatedHeightForHeaderInSection:)"
}
-->

# tableView(_:estimatedHeightForHeaderInSection:)

Asks the delegate for the estimated height of the header of a particular section.

```
optional func tableView(_ tableView: UITableView, estimatedHeightForHeaderInSection section: Int) -> CGFloat
```

## Parameters

`tableView`

The table view requesting this information.

`section`

An index number identifying a section of `tableView` .

## Return Value

A nonnegative floating-point value that specifies the height (in points) of the header for `section`.

## Discussion

Providing an estimate the height of section headers can improve the user experience when loading the table view. If the table contains variable height section headers, it might be expensive to calculate all their heights and so lead to a longer load time. Using estimation allows you to defer some of the cost of geometry calculation from load time to scrolling time.

## See Also

[`tableView(_:heightForHeaderInSection:)`](/documentation/UIKit/UITableViewDelegate/tableView(_:heightForHeaderInSection:))

Asks the delegate for the height to use for the header of a particular section.



---

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)