Back to Docs

<kbd>

Description

The <kbd> HTML element represents a span of inline text denoting user input from a keyboard, voice input, or any other text entry device. Browsers render the tag in monospace by default. Nesting <kbd> tags allows you to represent complex key shortcuts cleanly and accessibly.

Code Snippet

<p>
    Press <kbd>Ctrl</kbd> + <kbd>S</kbd> to save the document.
</p>

Static Live Preview

localhost/kbd-static.html

Press Ctrl + S to save the document.

Interactive Playground

localhost/kbd-interactive.html