JavaScript/String object
[i]Learn· Numbers and strings

String object

You can call methods directly on a string value:

console.log("hello".toUpperCase()); // HELLO

The following methods are available on String values:

When working with strings, there are two other objects that provide important functionality for string manipulation: RegExp and Intl. They are introduced in regular expressions and internationalization respectively.

Source: Numbers and strings by Mozilla Contributors, licensed under CC-BY-SA-2.5. Retrieved 2026-11-18. Changes: Extracted the section "String object"; removed the code-block language labels; made links absolute; examples are the page's own code blocks, unchanged.