HTMLTextAreaElement: value property - Web APIs | MDN

Value

A string containing the contents of the <textarea> element.

Examples

js

const textareaElement = document.getElementById("comment");
const oldText = textArea.value;
textArea.value = oldText.toUpperCase();

Specifications

Specification
HTML
# dom-textarea-value-dev

Browser compatibility

See also

Help improve MDN

Learn how to contribute

This page was last modified on by MDN contributors.