BITOR Function

Excel Functions › Engineering

Excel 2013+ Engineering

The Excel BITOR function returns the bitwise OR of two numbers (a bit is 1 where either input has 1) — bit-level math for flags, masks, and binary work.


Quick answer:
=BITOR(12, 10)

Syntax

=BITOR(number1, number2)
ArgumentDescription
number1RequiredA non-negative integer.
number2RequiredA non-negative integer.

How to use it

BITOR works on the binary bits of whole numbers — the foundation of flags, permissions masks, and low-level math.

=BITOR(12, 10) // 12 OR 10 = 14

Flags pattern: store on/off options as bits of one number, then test with BITAND and set with BITOR. BITLSHIFT/BITRSHIFT multiply/divide by powers of two. Inputs must be non-negative integers below 2^48.

Try it: interactive demo

Live demo

Change the inputs and watch the bitwise result (with binary shown).

Result:

Practice workbook

📊
Download the free BITOR practice workbook
Every example on this page, ready to open in Excel — plus practice challenges with answers on a separate tab. No sign-up required.

Frequently asked questions

Which Excel versions have the BIT functions?
Excel 2013 and later.
What are the input limits?
Non-negative integers from 0 up to 2^48 - 1. Negative or fractional inputs return #NUM!.
What is a real-world use?
Permission and option flags: pack many true/false settings into one integer, test with BITAND, toggle with BITOR/BITXOR.
How do shifts relate to multiplication?
BITLSHIFT(n,k) = n × 2^k and BITRSHIFT(n,k) = INT(n / 2^k).

Master functions like this in one day

This page covers one function. Our Excel Formulas and Functions class covers the 30 that matter most — live, hands-on, taught by professionals in Dallas–Fort Worth, Houston, Austin, Oklahoma City, Denver, or online.

See the Formulas & Functions Class

Related functions: BITAND · BITOR · BITXOR · BITLSHIFT