1 Kings 16:13

For all the sins of Baasha, and the sins of Elah his son, by which they sinned, and by which they made Israel to sin, in provoking the LORD God of Israel to anger with their vanities.

This verse belongs to the history of the kings after the division of the kingdom into ten tribes in Israel and two and a half tribes in Judah with war and strife between them, told in 1 Kings 12 to 16. That history is part of the larger sad record of 1 Kings 3-21 showing the general downward moral tendency in Israel and Judah after David, with times of reviving. Baasha slew Nadab and destroyed Jeroboam's family, ending the house of Jeroboam, and reigned twenty-four years. His son Elah succeeded him and his drunken reign lasted only two years until his captain Zimri slew him, ending the house of Baasha with him. Zimri reigned only seven days until he was slain by Omri, from whom sprang the wicked Ahab, whose reign brings the work of Elijah.

Elah repeated the history of Nadab as part of Israel's steady going from bad to worse since Jeroboam made Israel to sin, reigning only two years like Nadab and meeting death by violent hands. His murderer Zimri destroyed all his house and took the throne, bringing the same end upon the house of Baasha that had befallen the house of Jeroboam, as the prophet Jehu had predicted because Baasha followed in the way of Jeroboam. This history falls fifty years after the division, and the one good reign of Asa king of Judah spanned the reigns of all these wicked kings of Israel. The sins of Baasha and Elah by which they sinned and made Israel to sin were forsaking the worship of the living God and the God-given plan of worship which pointed to Christ and revealed the way of salvation from sin. They turned instead to idols, to the impure, untrue, and degrading worship of Baal and Ashtoreth, the worship of the creature instead of the Creator, transgressing God's commandments.

Their idolatrous vanities provoked the Lord God of Israel to anger. The verse shows the responsibility resting on leaders of God's people, that when king and priest are faithful to God and strong for Him they mold the people for good and when the people seek God He works for them and through them abundantly. But when leaders fail to lead in right ways the people fail with them, as Baasha and Elah sinned themselves and led Israel into sin. The verse is one stage in a great idolatrous apostasy in Israel during the days of Elijah surrounding Ahab and Jezebel, in which Baal worship corrupted Israel.

Their provoking of the Lord grew until it came to a climax in Ahab, who did more to provoke the Lord than all the kings before him by walking in the sins of Jeroboam the son of Nebat, taking Jezebel the daughter of Ethbaal to wife, serving and worshiping Baal, building him a temple, and making a grove for Ashtoreth. In that setting Elijah denounced the people's sin and called them back to worshiping Jehovah and obeying His law. The account gives this succession of violent coups and sin-marked, politically violent reigns in the kingdom of the Ten Tribes as the verse's historical setting but does not explain the verse's reference to Israel's sins or vanities.