The children of Israel were numbered via census twice by Moses and once by David.
Twice, GOD told Moses to take a census of the Israelites, by tribe, according to the number of men capable of fighting in the army.
The first census occurred at Mount Sinai and is recorded in Numbers 1. The second census occurred after the plague killed 24,000 due to Israel's idolatry and fornication with Midian. The second census is recorded in Numbers 26.
The third census was taken by King David, as recorded in 2 Samuel 24 and 1 Chronicles 21. While it was perfectly acceptable to take a census, something about David's census made it sinful and brought great calamity upon Israel. Most likely, this was because David failed to collect the ransom payment from those numbered, as GOD had instructed Moses:
11 Then the Lord spoke to Moses, saying, 12 “When you take the census of the children of Israel for their number, then every man shall give a ransom for his soul to the Lord, so there may be no plague among them when you number them. 13 This is what everyone among those who are numbered shall give: half a drachma according to the drachma of the sanctuary (a drachma is twenty obols). The half-drachma shall be an offering to the Lord. 14 Everyone included among those who are numbered, from twenty years old and above, shall give an offering to the Lord. 15 The rich shall not give more and the poor shall not give less than half a drachma when you give an offering to the Lord to make atonement for your souls. 16 You shall take the money of the offering of the children of Israel and shall give it for the service of the tabernacle of testimony, that it may be a memorial for the children of Israel before the Lord to make atonement for your souls.”
(Exodus 30:11-16 OSB)
These three census numberings went as follows. The number of men capable of serving in the army were:
- Census 1 – At Sinai: 603,530 (Numbers 1:46)
- Census 2 – At Moab: 601,730 (Numbers 26:51)
- Census 3 – David's: 1,100,000 (1 Chronicles 21:5)
Later, as recorded in 2 Chronicles 2:16-17, King Solomon took a census of the 153,600 foreigners in the land of Israel, pressing many of them into slave labor in building Solomon's temple.