Favorites

JavaScript Promise.reject() Method

☕
Enjoying this site?

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

Buy us a coffee
Promise.reject()
JavaScript Promise Static methodThis method is supported by all modern browsers.
Updated 28th November 2026

The Promise.reject() static method returns a promise that is already rejected with a given reason.

Description

The Promise.reject() static method returns a promise that is rejected with the given reason. Use an Error object as the reason so a stack trace is available. Inside an async function, throw does the same thing.

Unlike Promise.resolve(), it doesn't unwrap promises: passing a promise as the reason makes that promise object the rejection reason. A rejected promise with no catch() or try...catch attached produces an "unhandled rejection" warning in the console.

It's useful in functions that return promises when validation fails early, so callers always handle errors the same way: if (!id) return Promise.reject(new TypeError('id is required')).

Syntax

Promise.reject(reason)

Parameters

  • reasonThe rejection reason, usually an Error.

Return Value

A promise rejected with the reason.

Example

Promise.reject(new Error('Not allowed'))
  .catch(err => console.log('Caught:', err.message));

Browser Support

The following information will show you the current browser support for the Promise.reject() 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