The Book of Judges is the seventh book of the Old Testament and also the seventh book of the Bible. Judges chronicles the events in Israel's history, that occurred after Joshua's death to before Samuel the prophet's birth, focusing around "Judges". During this time Israel was falling away from God into idolatry, and God judged them for that by handing them over to their enemies.
When the enemies oppressed the people of Israel to the point where they cried out to God for deliverance, He raised up a man (and at one point a woman) to serve as a judge, who fought for the people to free them of their oppressors. However, when the judge died, the people fell back into idolatry again, and it became a repeated cycle. The primary judges featured in this book are Deborah, Gideon, Jephthah, and Samson.
The most commonly suggested author for Judges is Samuel.
The book is meant to document the period of the Judges, where Israel was more decentralized into separate tribes than as a unified nation and how Israel was allowed to be subjugated by foreign powers as a test, amid their immorality. Judges also clearly describes how God would repeatedly bring a deliverer for the people of Israel.
Judges clarifies several times in the ending of the book that Israel had no king, during many episodes of idolatry and inter-tribal warfare; saying everyone did as they wished. This would make the purpose of writing the book to show how Judges were not able restrain immorality in Israel.
Judges probably relies on oral tradition concerning the actions of the Judges and their lifespans, especially since Judges covers a period of several centuries. In particular the song of Deborah and Barak, probably would have been memorized and then recited orally. There is one specific example where it is certain a written document was used as a source. A short account of how Caleb gave his daughter to Othniel is copied directly from Book of Joshua.