Assuming you are talking about the U.S.:
While there were some law schools at which you could get a formal education, it was not a requirement in most states. You could practice law after serving as an apprentice at a law firm and passing the bar exam.