DEV Community

Cover image for Back to Top button with smooth scroll
SnippFlow
SnippFlow

Posted on

1

Back to Top button with smooth scroll

A “Back to Top” button is a simple yet useful feature that helps with navigation especially on long pages. This button gives users a quick way to get back to the top of the page without excessive scrolling.

See the following Codepen for a demo:

Full article: Back to Top button with smooth scroll
CSS Snippets

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay