Testing the output element

The <output> element is a container element into which the results of a calculation or the outcome of a user action can be injected.

Example

Use the form below to add two values together and calculate the result:

+ = 0
The total value is 0
<input type="number" id="a" aria-label="Value 1"> +

<input type="number" id="b" aria-label="Value 2"> =

<output name="result" id="result">0</output>

<div aria-live="polite">
  <!-- Dynamic message -->
</div>