# head

> For the complete documentation index, see [llms.txt](https://kotlin.github.io/dataframe/llms.txt).

Returns a [DataFrame](dataframe.html) containing the first `n` (default 5) rows.

API reference: [head](https://kotlin.github.io/dataframe/api-docs/core/org.jetbrains.kotlinx.dataframe.api/head.html)

```KOTLIN
df.head(3)
```

[Embedded content](resources/org.jetbrains.kotlinx.dataframe.samples.api.Analyze.head.html)

Similar to [take](slicerows.html#take).

