Round any number up to the nearest integer using the ceiling function.
Last updated: June 2026 | By Patchworkr Team
The ceiling function returns the smallest integer greater than or equal to a real number. In practice, that means it rounds upward to the next whole number unless the value is already an integer.
This makes it useful whenever you need a whole-number result that must not fall below the original value.
The ceiling and floor functions round in opposite directions. The ceiling function rounds a number up to the smallest integer greater than or equal to the value, while the floor function rounds down to the largest integer less than or equal to the value.
For example, ceil(3.2) = 4 while floor(3.2) = 3. Looking at both together makes it easier to see where a number sits between two integers.
Ceiling does not always mean moving away from zero. For negative numbers, the ceiling moves toward zero because it finds the smallest integer greater than or equal to the value.
For example, ceil(-3.7) = -3, not -4. If the number is already an integer, the ceiling leaves it unchanged.
ceil(7.3) = 8
ceil(-3.7) = -3
ceil(5) = 5
Can ceiling decrease a number?
No. It always stays the same or rounds up.
What happens with integers?
The ceiling of an integer is the integer itself.
How does it behave for negatives?
It rounds toward positive infinity.
What if I enter invalid text?
The calculator shows an error until a valid number is entered.
Related Tools