Loading…

Divisibility Tester (up to 20)

Math Algebra • Numbers

View all topics

Test an integer against common divisibility rules. For a nonzero divisor \(d\), \[ \begin{aligned} d\mid n \quad \Longleftrightarrow \quad n=dq \end{aligned} \] for some integer \(q\). This calculator checks divisors from \(2\) through \(20\), shows the remainder, and explains the rule used.

Number and divisor set

Negative numbers are tested using \(|n|\), because divisibility does not change with sign. The number \(0\) is divisible by every positive divisor.

Quick examples

Ready
Enter an integer, then click “Calculate”.

Rate this calculator

0.0 /5 (0 ratings)
Be the first to rate.
Your rating
You can update your rating any time.

Frequently Asked Questions

What does it mean for a number to be divisible by another number?

An integer n is divisible by a nonzero integer d if n = d × q for some integer q. Equivalently, the remainder when n is divided by d is 0.

Which divisors does this calculator test?

It can test all divisors from 2 through 20, the basic set from 2 through 12, or a custom subset from 2 through 20.

How does the calculator handle negative numbers?

It applies the digit rules to the absolute value of the number because d divides n if and only if d divides |n|.

Is zero divisible by every divisor?

Zero is divisible by every positive divisor because 0 = d × 0 for any positive integer d.

What is the rule for divisibility by 3?

A number is divisible by 3 if the sum of its digits is divisible by 3.

What is the rule for divisibility by 9?

A number is divisible by 9 if the sum of its digits is divisible by 9.

What is the rule for divisibility by 11?

A number is divisible by 11 if the difference between the alternating sums of its digits is divisible by 11.

What is the rule for divisibility by 8?

A number is divisible by 8 if its last three digits form a number divisible by 8.

What is the rule for divisibility by 16?

A number is divisible by 16 if its last four digits form a number divisible by 16.

Does passing none of the tests from 2 through 20 mean the number is prime?

No. It only means none of those small divisors divide the number. A composite number may still have a divisor larger than 20.