JavaScript String Properties

Beginner
5 min read
Updated: Nov 2026
2 property guides
Property index

About This Index

This page is the JavaScript String Properties index for the tutorial track. Each row links to a full guide with syntax, examples, and FAQs.

Learn what a String is on /js/string. Use this page for length and constructor. Functions such as slice() live on the String Methods index.

Read, do not call.

"Hello".length is a number. "Hello".length() throws, because length is not a function.

How to Read a String Property

Properties are values on the string. No parentheses:

JavaScript
const title = "JavaScript";

title.length;            // 10
"".length;               // 0
"😀".length;             // 2  (UTF-16 code units)
title.constructor;       // String
typeof title;            // "string"

JavaScript String Properties Table

Property guides in this JavaScript tutorial series (2 tutorials).

Instance properties

2 properties

Read these on a string value. They are data, so you do not call them with parentheses.

PropertyDescriptionTutorial
lengthRead-only count of UTF-16 code units. An emoji such as 😀 can count as 2.Open
constructorThe function that created the string. For a string primitive it is String. Call String(value) to convert; avoid new String().Open

Frequently Asked Questions

In this tutorial series the String property guides are length and constructor. length is the read-only UTF-16 code-unit count on a string. constructor is the function that created it, which is String for a string primitive.
The String page teaches what a String is—quotes, template literals, and immutability. This Properties index lists the property tutorials. Methods such as slice() and trim() are on the String Methods index.
You read a property with no parentheses: "Hello".length. You call a method: "Hello".slice(0, 2). Methods are functions; length is a number.
length counts UTF-16 code units. "Hi".length is 2. Many emoji use two code units, so "😀".length is also 2 even though you see one character.
If you are new, read JavaScript String first. Then open length. Use the Methods index when you need slice(), includes(), or trim().

Start with length

Open the property guide—syntax, emoji pitfalls, and FAQs.

length tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful