Ezra fasts because he is dismayed by the sin of the people and eager to intercede before God on their behalf. Relocating himself to a more private place, he is able to continue in prayer without distraction. His confession (Ezra 9:6–15) noted that in the past God had forgiven the people and blessed them after they confessed their sins; therefore, it was logical to believe there was hope for God’s grace once again if they would truly confess their sins now.1
6 Then Ezra withdrew from before the house of God and went to the chamber of Jehohanan the son of Eliashib, where he spent the night, neither eating bread nor drinking water, for he was mourning over the faithlessness of the exiles.