Favorites

JavaScript Function.prototype.call() Method

☕
Enjoying this site?

Help keep it running with a small coffee donation. Every bit of support is appreciated!

Buy us a coffee
Function.prototype.call()
JavaScript Function Instance methodThis method is supported by all modern browsers.
Updated 28th November 2026

The call() method calls a function with a given this value and arguments listed one by one.

Description

The call() method calls the function immediately with a chosen this value and arguments listed individually. It's used to borrow methods from other objects, such as Array.prototype.slice.call(arguments), although modern alternatives like Array.from() usually exist.

Passing null or undefined as thisArg is fine when the function doesn't use this. call() and apply() run the function straight away, whereas bind() returns a new function for later.

A classic use is calling a parent constructor from a child constructor in pre-class code, Parent.call(this, name); with classes, super(name) does that job. Arrow functions ignore the thisArg argument.

Syntax

func.call(thisArg)
func.call(thisArg, arg1, arg2, ...)

Parameters

  • thisArgThe value to use as this inside the function.
  • arg1, arg2, ...Optional. Arguments for the function.

Return Value

The result of calling the function.

Example

function intro(role) {
  return this.name + ' is a ' + role;
}
console.log(intro.call({ name: 'Alex' }, 'designer'));
console.log(Object.prototype.toString.call([]));

Browser Support

The following information will show you the current browser support for the Function.prototype.call() method. Hover over a browser icon to see the version that first introduced support for this method.

This method is supported by all modern browsers.

Desktop

Chrome
Edge
Firefox
Opera
Safari

Tablets & Mobile

Chrome Android
Firefox Android
Opera Android
Safari iOS
Samsung Internet
Android WebView
-
Supported Unknown Not supported
☕
Enjoying this site?

Help keep it running with a small coffee donation. Every bit of support is appreciated!

Buy us a coffee