Divisibility Rules 1 to 20: The Complete List With Examples
Divisibility rules for 1 to 20 in one chart. Learn the quick test for each divisor, why the digit-sum and alternating-sum rules work, and how each rule reveals the remainder.
Divisibility rules are shortcuts that tell whether one number divides another exactly, without doing the full division. A number is divisible by a divisor when applying the divisor’s rule leaves a remainder of zero, so 1,234 is divisible by 2 because its last digit is even, and by 3 because its digits sum to 10, which they do not, so it fails the rule for 3. The Remainder Calculator confirms any result instantly, and the chart below gives the exact test for every divisor from 1 to 20.
Divisibility rules deliver 3 benefits: they replace long division with a single mental step, they reveal a remainder of zero before any calculation starts, and they speed up factoring, fraction reduction and prime testing. The rules are used in arithmetic homework, mental math, number theory and code that must test divisibility in one operation.
Each divisibility rule works on one of 4 features of a number: its last digit, its last few digits, its digit sum, or its alternating digit sum. This guide gives the full chart for 1 to 20, explains each method group with worked examples, and shows how every rule connects to the remainder.
What Are Divisibility Rules?
Divisibility rules are tests that check whether a dividend divides evenly by a divisor, returning a remainder of zero. A rule inspects the digits of the number instead of performing the division, so the answer takes one step.
A number passes a divisibility rule when the divisor is a factor of that number. The statement “84 is divisible by 4” means 84 ÷ 4 = 21 with a remainder of 0, so 4 is a factor of 84, which is what a remainder of zero means. Every rule below is a fast way to reach that same yes-or-no answer, and a failed rule points to finding the leftover when a rule fails through ordinary division.
Divisibility Rules Chart (1 to 20)
The chart lists the quick test for each divisor from 1 to 20.
| Divisor | Rule | Example |
|---|---|---|
| 1 | Every whole number is divisible by 1 | 7 → yes |
| 2 | Last digit is even (0, 2, 4, 6, 8) | 58 → yes |
| 3 | Digit sum is divisible by 3 | 51 → 5+1=6 → yes |
| 4 | Last two digits divisible by 4 | 316 → 16 → yes |
| 5 | Last digit is 0 or 5 | 245 → yes |
| 6 | Divisible by both 2 and 3 | 132 → yes |
| 7 | Double the last digit, subtract from the rest, check for 7 | 672 → 67−4=63 → yes |
| 8 | Last three digits divisible by 8 | 7,192 → 192 → yes |
| 9 | Digit sum is divisible by 9 | 621 → 6+2+1=9 → yes |
| 10 | Last digit is 0 | 470 → yes |
| 11 | Alternating digit sum is divisible by 11 | 121 → 1−2+1=0 → yes |
| 12 | Divisible by both 3 and 4 | 348 → yes |
| 13 | Multiply the last digit by 4, add to the rest, check for 13 | 169 → 16+36=52 → yes |
| 14 | Divisible by both 2 and 7 | 182 → yes |
| 15 | Divisible by both 3 and 5 | 225 → yes |
| 16 | Last four digits divisible by 16 | 4,096 → yes |
| 17 | Multiply the last digit by 5, subtract from the rest, check for 17 | 221 → 22−5=17 → yes |
| 18 | Divisible by both 2 and 9 | 342 → yes |
| 19 | Multiply the last digit by 2, add to the rest, check for 19 | 209 → 20+18=38 → yes |
| 20 | Last two digits are 00, 20, 40, 60 or 80 | 380 → yes |
Rules for 2, 5 and 10: Read the Last Digit
The rules for 2, 5 and 10 depend only on the final digit of the number. A single glance answers each one.
- Divisible by 2 when the last digit is even, so 0, 2, 4, 6 or 8. The number 58 ends in 8, so 58 is divisible by 2.
- Divisible by 5 when the last digit is 0 or 5. The number 245 ends in 5, so 245 is divisible by 5.
- Divisible by 10 when the last digit is 0. The number 470 ends in 0, so 470 is divisible by 10.
These 3 rules work because 10 is divisible by 2, 5 and 10, so every digit above the last contributes a multiple of the divisor. Only the final digit can leave a remainder, and these same last-digit checks appear among the shortcuts for when the number does not divide evenly.
Rules for 3 and 9: Add the Digits
The rules for 3 and 9 use the digit sum. Add every digit, and if the total is divisible by 3 or 9, the whole number is too.
Test 621 for divisibility by 9: 6 + 2 + 1 = 9, which is divisible by 9, so 621 is divisible by 9. Test 51 for divisibility by 3: 5 + 1 = 6, which is divisible by 3, so 51 is divisible by 3.
The digit sum works because 10, 100 and every power of 10 leaves a remainder of 1 when divided by 9, and also when divided by 3. Each digit therefore contributes only its own value to the remainder. When the digit sum is not a multiple, its remainder after dividing by 3 or 9 equals the remainder of the original number.
Rules for 4, 8 and 16: Check the Last Digits
The rules for 4, 8 and 16 examine the last few digits, because these divisors are powers of 2.
- Divisible by 4 when the last two digits form a number divisible by 4. The number 316 ends in 16, and 16 ÷ 4 = 4, so 316 is divisible by 4.
- Divisible by 8 when the last three digits form a number divisible by 8. The number 7,192 ends in 192, and 192 ÷ 8 = 24, so 7,192 is divisible by 8.
- Divisible by 16 when the last four digits form a number divisible by 16. The number 4,096 ÷ 16 = 256, so 4,096 is divisible by 16.
Each rule checks one more digit than the last, because 100 is divisible by 4, 1,000 is divisible by 8, and 10,000 is divisible by 16. Every digit beyond that range contributes a clean multiple of the divisor.
Rule for 11: Alternate the Signs
The rule for 11 uses the alternating digit sum. Add the last digit, subtract the next, add the next, and continue; if the result is divisible by 11, so is the number.
Test 121 for divisibility by 11: 1 − 2 + 1 = 0, which is divisible by 11, so 121 is divisible by 11. Test 918,082: 2 − 8 + 0 − 8 + 1 − 9 = −22, which is divisible by 11, so 918,082 is divisible by 11.
The alternating pattern works because 10 leaves a remainder of −1 when divided by 11, so each digit position flips sign. A result of 0 always counts as divisible.
Rules for 7, 13, 17 and 19: Multiply and Combine
The rules for 7, 13, 17 and 19 remove the last digit, multiply it by a fixed number, and combine it with the remaining digits. Repeat until the result is small enough to check.
- Divisible by 7: double the last digit and subtract it from the rest. For 672, remove the 2, then 67 − (2 × 2) = 63, and 63 is divisible by 7, so 672 is divisible by 7.
- Divisible by 13: multiply the last digit by 4 and add it to the rest. For 169, remove the 9, then 16 + (9 × 4) = 52, and 52 is divisible by 13, so 169 is divisible by 13.
- Divisible by 17: multiply the last digit by 5 and subtract it from the rest. For 221, remove the 1, then 22 − (1 × 5) = 17, and 17 is divisible by 17, so 221 is divisible by 17.
- Divisible by 19: multiply the last digit by 2 and add it to the rest. For 209, remove the 9, then 20 + (9 × 2) = 38, and 38 is divisible by 19, so 209 is divisible by 19.
These 4 rules trade a hard division for a short multiplication, and they repeat cleanly on large numbers by shrinking the digit count each pass.
Rules for 6, 12, 14, 15, 18 and 20: Combine Two Rules
The rules for composite divisors combine the rules of their coprime factors. A number is divisible by the composite when it passes both simpler tests.
- Divisible by 6 when it passes the rules for 2 and 3. The number 132 is even and its digits sum to 6, so 132 is divisible by 6.
- Divisible by 12 when it passes the rules for 3 and 4. The number 348 sums to 15 and ends in 48, so 348 is divisible by 12.
- Divisible by 14 when it passes the rules for 2 and 7. The number 182 is even and 18 − 4 = 14, so 182 is divisible by 14.
- Divisible by 15 when it passes the rules for 3 and 5. The number 225 sums to 9 and ends in 5, so 225 is divisible by 15.
- Divisible by 18 when it passes the rules for 2 and 9. The number 342 is even and sums to 9, so 342 is divisible by 18.
- Divisible by 20 when its last two digits are 00, 20, 40, 60 or 80. The number 380 ends in 80, so 380 is divisible by 20.
Combining rules works only when the two factors share no common divisor. Checking 12 with the rules for 2 and 6 would fail, because 2 and 6 both contain a factor of 2, so a number could pass both without being divisible by 12.
How Divisibility Rules Relate to Remainders
Every divisibility rule is a remainder test in disguise. A number passes a rule exactly when its remainder for that divisor is 0, and several rules return the exact remainder, not just a yes or no.
The digit-sum rule for 9 gives the remainder directly: the digits of 1,234 sum to 10, and 10 leaves a remainder of 1 when divided by 9, so 1,234 ÷ 9 also leaves 1. The alternating-sum rule for 11 does the same: for 1,234 the alternating sum 4 − 3 + 2 − 1 = 2, so 1,234 ÷ 11 leaves 2. These shortcuts reach the same values that the full long division method produces, only faster.
How to Use Divisibility Rules in Code
A program tests divisibility with the modulo operator, writing n % d == 0 to check whether d divides n exactly. The expression returns true when the remainder is 0.
The check 144 % 12 == 0 returns true, so 12 divides 144. The check 145 % 12 == 0 returns false, since 145 % 12 returns 1. This one-line test replaces every hand rule inside code and drives loops that filter multiples, and it behaves the same for positive divisors across modulo in Python, JavaScript and C. Because a zero remainder has no sign, the divisibility test stays correct even for the remainder of a negative number, where other results differ by language. The operator itself is covered in testing divisibility in code.
Divisibility Rules and Prime Numbers
Divisibility rules are the fastest way to test a number for primality. A number is prime when no divisor from 2 up to its square root leaves a remainder of 0.
Testing 97 for primality needs only the divisors 2, 3, 5 and 7, since 7 is the largest integer below √97. The number 97 is odd, its digits sum to 16, it does not end in 0 or 5, and the rule for 7 gives 9 − 14 = −5, which is not divisible by 7. All 4 rules fail to divide, so 97 is prime. Running the quick rules first is the fastest start to testing a number for primality, ruling out most composites in seconds.
Common Mistakes
Four errors cause most wrong divisibility results:
- Combining two rules that share a factor, such as testing 12 with the rules for 2 and 6 instead of 3 and 4.
- Forgetting that a digit sum or alternating sum of 0 still counts as divisible.
- Checking only the last digit for 4 or 8, when 4 needs the last two digits and 8 needs the last three.
- Assuming a number divisible by 2 and by 4 needs both tests, when the rule for 4 already implies the rule for 2.
Frequently Asked Questions
What are the divisibility rules from 1 to 20?
The divisibility rules from 1 to 20 test each divisor with the last digit, the last few digits, the digit sum, or the alternating digit sum. Composite divisors like 6, 12 and 15 combine the rules of their coprime factors.
What is the divisibility rule for 7?
The divisibility rule for 7 doubles the last digit and subtracts it from the rest of the number. For 672, the calculation 67 − (2 × 2) = 63 is divisible by 7, so 672 is divisible by 7.
How do divisibility rules relate to remainders?
Divisibility rules relate to remainders because a number passes a rule exactly when its remainder is 0. The digit-sum rule for 9 and the alternating-sum rule for 11 return the exact remainder, not just a yes-or-no answer.
Why does adding the digits test for divisibility by 3 and 9?
Adding the digits tests for 3 and 9 because every power of 10 leaves a remainder of 1 when divided by 3 or 9. Each digit contributes only its face value, so the digit sum shares the remainder of the whole number.
What is the easiest way to check large numbers?
The easiest way to check large numbers is the modulo operator, writing n % d == 0 in code. For mental math, the multiply-and-combine rules for 7, 13, 17 and 19 shrink the number one digit at a time.
Conclusion
Divisibility rules from 1 to 20 reduce division to one step by reading a number’s last digit, last few digits, digit sum, or alternating digit sum. The rules for 2, 5 and 10 read the final digit, the rules for 3 and 9 add the digits, the rules for 4, 8 and 16 check the last digits, and the composite divisors combine two coprime rules.
Every rule is a remainder test, and the digit-sum and alternating-sum methods return the exact remainder for 3, 9 and 11. Those 3 benefits, a shorter calculation, an instant zero-remainder test, and faster prime checking, make the rules the practical layer over full division. Enter any dividend and divisor into the Remainder Calculator to confirm a rule against the exact remainder.