A piece of text in your code, wrapped in quotes like 'hello' or "world".
A string is text data in your code. It is called a 'string' because it is a sequence of characters strung together. Strings must be wrapped in quotes (single, double, or backticks) so JavaScript knows it is text, not code.
Strings are one of the most fundamental data types. You use them for names, messages, URLs, and any text. JavaScript provides methods to manipulate strings—find characters, replace text, convert case, split into parts. Strings are stored in variables, passed as props to components, encoded in JSON, and displayed in code editors with syntax highlighting.
Understanding strings is essential because text appears everywhere in code. You will read strings from user input, display them on pages, and send them to servers.
Learn the concepts, fix things with confidence, and ship real products with AI beside you. No coding background required, and we're with you from the first idea to launch.
Free to start. No card. Leave whenever you want.