History of racial segregation in the United States
In 1896, in a case called Plessy v. Ferguson, the Supreme Court ruled that these laws were legal.  They said that segregation was fine, as long as things were "separate but equal."  In the South, everything was separate.  However, places like black schools and libraries got much less money and were not as good as places for whites.  Things were separate, but not equal.