Skip to main content

When is a promise considered "fulfilled"?

Short answer

A promise is considered "fulfilled" when the asynchronous operation has completed successfully and the resolve() function has been called - that is, the promise now has a result (value).


Formally, in ECMAScript

A Promise object has three states:

StateWhat it meansCan it change
pending"waiting" - the result is not yet knownYes
fulfilled"completed successfully" - resolve() was calledNo
rejected"completed with an error" - reject() was calledNo

After moving to fulfilled or rejected - the state becomes final (immutable).


Example: a promise becomes "fulfilled"

javascript
const promise = new Promise((resolve, reject) => { setTimeout(() => { resolve('Data received'); }, 1000); }); promise.then((result) => { console.log(result); });

After 1 second, resolve('Data received') is called -> the promise moves from pending -> to fulfilled, and .then() runs.


When it is not considered fulfilled

1. As long as resolve() or reject() has not been called

javascript
new Promise(() => { // we call nothing }); // state: pending (forever)

2. If the promise resolves with another promise (chaining)

javascript
const p = new Promise((resolve) => { resolve(fetch('/data')); // resolve returns another Promise });

Then p will not settle until the nested Promise settles. (the "promise unwrapping" mechanism).


Example with reject (an error)

javascript
const promise = new Promise((resolve, reject) => { reject('Network error'); }); promise .then(() => console.log('Success')) .catch((err) => console.error(err));

The promise is settled, but in the rejected state, so .catch() runs.


When .then() / .catch() run

  • .then() fires only if the promise becomes fulfilled
  • .catch() fires if it becomes rejected
  • .finally() fires in any case, once the promise settles

Timing example

javascript
const p = new Promise((resolve) => { console.log('1 pending'); setTimeout(() => resolve('2 fulfilled'), 2000); }); p.then(console.log); console.log('3 continuing execution');

Sequence:

javascript
1 pending 3 continuing execution 2 fulfilled

The promise is "fulfilled" only after 2 seconds - at the moment resolve() is called.


Summary: what "Promise fulfilled" means

StateWhat happenedMethods that fire
pendingoperation in progressnone
fulfilledresolve() was called.then(), .finally()
rejectedreject() was called, or an error occurred.catch(), .finally()

A simple analogy

A promise is like a delivery

  • While the order hasn't arrived -> pending
  • The courier arrived with the package -> fulfilled
  • The courier called: "address not found" -> rejected

Conclusion

A Promise is considered "fulfilled" when it moves from the pending state -> to one of the final ones:

  • fulfilled - successfully (resolve(value))
  • rejected - with an error (reject(reason))

After that:

  • the state no longer changes,
  • and the result can be obtained via .then(), .catch(), or await.

Short Answer

Interview ready
Premium

A concise answer to help you respond confidently on this topic during an interview.