Operators

Right shift (>>)

Try the free JavaScript compiler

Moves bits right with sign extension. Number results are signed 32-bit, and the shift count is reduced to its low five bits.

Formal Syntax & Structure

javascript syntaxjavascript
left >> right

Parameters & Attributes

NameTypeDescription
leftexpressionLeft operand.
rightexpressionRight operand; short-circuiting may skip evaluation where applicable.

Return Value

Number or BigInt

Result of the operation.

Working Example

Example Snippetjavascript
console.log(-8 >> 1);
JavaScript Reference