Divisibility Test Calculator
A number and a divisor into the truncated quotient, the remainder with the dividend's sign, and the verdict.
What the divisibility test calculator does
It divides one integer by another and reports whether the division is exact. The quotient is truncated toward zero, the remainder keeps the dividend's sign, and the verdict says divisible or not. The check line multiplies the divisor by the quotient and adds the remainder, so the answer can be verified by hand.
123456 divided by 7 gives a quotient of 17636 and a remainder of 4, so 123456 is not divisible by 7, and 7 × 17636 + 4 is 123456. A remainder of 0 is the only thing that makes a number divisible; the page does not round the quotient to make it look exact.
The truncated quotient and dividend-signed remainder are the same convention the catalogue's quotient-and-remainder page states, so the two pages agree on negative inputs: −9 ÷ 4 gives −2 and a remainder of −1.
Both values must be whole numbers. A divisor of 0 is refused because it has no quotient and no remainder, and an integer past 10¹⁵ is refused because a JavaScript number stops being exact there. A fractional input and a non-numeric token are refused by name.
How to use it
Enter the Number and the Divisor.
Press Run. The result prints the quotient, the remainder, the verdict and the check line.
Worked example
Input with the defaults:
123456 ÷ 7
Output:
Quotient: 17636 (truncated toward zero)
Remainder: 4 (the dividend keeps its sign)
Verdict: 123456 is not divisible by 7
Check: 7 × 17636 + 4 = 123456
Why it runs in your browser
The division runs in this tab. Your numbers are never uploaded.
The page divides one integer by another and reports whether the division is exact. 123456 divided by 7 gives a quotient of 17636 and a remainder of 4, so it is not divisible by 7.
The quotient is truncated toward zero and the remainder keeps the dividend's sign — the same rule the quotient-and-remainder page states, so the two pages agree on negative inputs.
The check line multiplies the divisor by the quotient and adds the remainder, so the answer can be verified without trusting the verdict line.
Truncation and the sign of the remainder
Integer division here truncates toward zero rather than flooring: −9 ÷ 4 gives a quotient of −2, not −3. The remainder is what is left over from that quotient, so −9 ÷ 4 leaves −1, keeping the dividend's sign.
This is the convention JavaScript's remainder operator uses, and it is also the one the catalogue's quotient page uses. Stating it matters because a floored division would give a different remainder for every negative input.
The exactness cap
Both integers are read up to 10¹⁵. Past that, a JavaScript number can no longer represent every integer, so a divisibility verdict would be a rounding artefact rather than arithmetic. The page refuses a larger value and says why.
How to use Divisibility Test Calculator
Enter the Number and the Divisor.
Press Run. The result prints the quotient, the remainder, the verdict and the check line.
What to Expect
Best for
- Checking whether one integer divides another exactly
- Reading the quotient and remainder of a division in one step
- Verifying the answer with the printed check line
Not ideal for
- Prime factorisation, which is a different page
- Decimals or fractions, which are not integers
- A divisor of zero, which has no quotient
What this tool keeps
- The number and the divisor as typed
- The sign of the dividend
What may need cleanup
- A number with a thousands separator, which must be entered without it
- A value past 10¹⁵, which must be handled in another tool
Common errors
- Expecting a floored quotient for a negative number
- Reading a remainder of 4 as a pass because the quotient looks close
Example use cases
- Testing a divisibility rule by hand
- Finding the remainder of a large division
- Checking a mental arithmetic answer
Sample input
123456 divided by 7.
Sample output
A quotient of 17636, a remainder of 4, and the verdict that 123456 is not divisible by 7.
Who this is for
- Students checking a division
- Anyone testing an exact division quickly
Frequently asked questions
Why is the remainder 4 and not 0.5714?
The page reports integer division: a quotient and what is left over. 123456 ÷ 7 is 17636.5714, so the integer quotient is 17636 and the remainder is 4. The check line adds them back to 123456.
Why is −9 ÷ 4 a remainder of −1?
The quotient is truncated toward zero, giving −2, and the remainder is what makes −2 × 4 + r equal −9. That r is −1, so the remainder keeps the dividend's sign.
Can I enter a decimal?
No. Divisibility is a property of integers. A decimal in either field is refused with the value named.
What is the largest number the page reads?
10¹⁵, because past that a JavaScript number cannot represent every integer exactly and the verdict would be a rounding artefact.
Build custom tools for your store
Join the SDK program to create useful ecommerce utilities for your store.