Learning JavaScript? Download my free JavaScript Handbook 🔥

Called on an object instance, returns a string representation of the object. Returns the [object Object] string unless overridden. Objects can then return a string representation of themselves.

const person = { name: 'Fred' }
person.toString() //[object Object]

Edit this page


Here's my latest YouTube video. I talk about work/life balance as a developer: