Open this example in the interactive library
Source code
<div class="demo overflow-y-auto scroll-pt-4 h-24">
<a href="#end">Jump to end</a>
<p style="height: 8rem">Scrollable content</p>
<p id="end" style="min-height: 5rem">Target with top padding</p>
</div>