In everyday English people mix the words call and invoke, and blog posts sometimes imply they are different ECMAScript operators. In the language itself both words describe the same idea: a function’s body runs with a specific set of arguments and a resolved this binding. What actually changes behavior is the call form you choose—fn(), obj.method(), fn.call(ctx), new Constructor(), and so on—because those forms set this, new.target, and strict-mode rules, not the vocabulary in your comment.
This page clears up that vocabulary, shows this on a normal method call versus Function.prototype.call, and disambiguates the .call() method name from “calling a function.” After each runnable snippet, a short note describes what you should see in the console.
Tested on: Node.js v20.18.2.
Quick reference
Use this table for invoke vs call in programming when reading JavaScript docs.
| Phrase in English | In JS it usually means |
|---|---|
| Call / invoke / run / execute | Evaluate the function body with arguments |
obj.m() |
Call m with this === obj |
fn.call(ctx, a, b) |
Call fn with this === ctx and arguments a, b |
1. “Calling” and “invoking” are usually synonyms
If you invoke a function or call a function, you are scheduling it to execute with arguments and producing a return value (or undefined). Docs and blogs pick one word for style; there is no hidden second mechanism in the engine keyed off the English word invoke alone.
2. Direct call: add(5, 10)
A free function call passes arguments positionally; this inside a non-strict simple function is still the global object (or undefined in strict modules), not relevant here because add does not use this.
function add(arg1, arg2) {
return arg1 + arg2;
}
const result = add(5, 10);
console.log(result);You should see 15.
3. Method call: this comes from the call form, not from the word “invoke”
arr.push(34) is still a function call. push runs with this set to arr because you used property access (object.method()), not because someone calls the operation an “invoke” in casual writing.
const arr = [1, 34, 212, 12];
arr.push(34);
console.log(arr);You should see the array with 34 appended at the end: [1, 34, 212, 12, 34] (Node formats with spaces after commas).
For invoke vs call in programming interviews, the teaching point in JavaScript is how you accessed the function (free call vs method call vs .call/.apply/.bind/constructor call), not the verb you use in English.
4. Explicit this with Function.prototype.call (the method named call)
This is the usual confusion: fn.call(obj, 1, 2) uses the .call method to run fn with this === obj. That is still one function execution—you are not switching from a “call” to a different magical “invoke” mode.
const o = { x: 1, getX() { return this.x; } };
const p = { x: 99 };
console.log(o.getX());
console.log(o.getX.call(p));Two lines: 1 from o.getX() with this === o, then 99 from getX.call(p) with this === p via Function.prototype.call.
5. js invoke in APIs (not the language core)
Some libraries expose a method literally named invoke (for example collection helpers). That is a library identifier, not proof that the JavaScript engine distinguishes “invoke” from “call” in grammar.
6. Related reading on this site
- Functions as values — how storing functions relates to later calling them.
- Arrow functions — lexical
thisand why call-site rules differ from ordinary functions.
Summary
- “Call” and “invoke” in everyday writing both mean executing a function body in JavaScript.
thisfollows call-site rules (obj.m(),m.call(ctx),new, arrows), not vocabulary.Function.prototype.callis an API for explicitthis; it is not a separate “invoke” opcode.
References
MDN guides for functions, this, and Function.prototype.call.
- MDN: Functions
- MDN:
Function.prototype.call() - MDN:
this
Frequently Asked Questions
In JavaScript, is there a real difference between call and invoke?
In everyday JavaScript usage, call and invoke both mean execute the function. The language specification and MDN do not reserve invoke for a different kind of execution than call.
Why do some articles say invoke sets this but call does not?
That is misleading for JavaScript. this is determined by how the function is run (call site), for example obj.method(), fn.call(ctx), new Ctor(), or an arrow function’s lexical this—not by whether you use the English word invoke or call.
What is Function.prototype.call then?
It is a built-in method on function objects. fn.call(thisArg, a, b) calls fn with this set to thisArg. The word call in the method name is separate from the general phrase calling a function.
Is arr.push(1) an invoke javascript function case?
It is a method call. push is a function on Array.prototype; the call form object.property() sets this to object inside push, which is why it mutates that array.
What does invoke meaning in programming refer to outside JS?
Other languages or runtimes sometimes distinguish invoke (dynamic dispatch, reflection) from call. In JS, people still usually mean the same thing unless they name a specific API invoke.
Where can I read more about functions as values and this?
See the guides on functions as first-class values and arrow functions for how references and lexical this interact with calls.
