HTML · Text and inline semantics

code

A fragment of computer code. Use it inline; wrap longer blocks in pre.

Syntax
<code>…</code>

Example

Try it

More in this group

abbr b bdi bdo blockquote br cite data (element)

Learn this in the course

Reference pages are the quick answer. The course explains the why, shows the full example and ends with a challenge.

Open the course