Athaliah (the Queen mother) rules Judah until her grandson and rightful heir, Joash, comes out of hiding and is crowned by the priests, who then bring in major religious reforms: 2 Kings 11:1−3; 2 Chronicles 22:10−12; 2 Kings 11:4−12; 2 Chronicles 23:1−11; 2 Kings 11:13−16; 2 Chronicles 23:12−15; 2 Kings 11:17−21; 2 Chronicles 23:16−21; 2 Kings 12:1−16; 2 Chronicles 24:1−22; 2 Kings 10:32−36
Raised by the Temple priest, Joash was a good king to begin with:
2 Kings 12:2-3 All his life Joash did what was pleasing in the Lord’s sight because Jehoiada the priest instructed him. Yet even so, he did not destroy the pagan shrines, and the people still offered sacrifices and burned incense there.
But it lasted only as long as Jehoiada the priest (who installed him as king) was around to advise him:
2 Chronicles 24:17-18 But after Jehoiada’s death, the leaders of Judah came and bowed before King Joash and persuaded him to listen to their advice. They decided to abandon the Temple of the Lord, the God of their ancestors, and they worshiped Asherah poles and idols instead!
Jehoiada’s son, Zechariah, and other prophets relayed God’s view of this, but neither the people nor King Joash listened, instead:
2 Chronicles 24:21-22 Then the leaders plotted to kill Zechariah, and King Joash ordered that they stone him to death in the courtyard of the Lord’s Temple. That was how King Joash repaid Jehoiada for his loyalty—by killing his son. Zechariah’s last words as he died were, ‘May the Lord see what they are doing and avenge my death!’