For decades, Americans living in certain neighborhoods couldn’t borrow money to buy houses and build businesses. These neighborhoods were home to people of color, immigrants and poor white people. Banks, real-estate agents, local officials and the federal government labeled their neighborhoods “hazardous,” marking them off with red lines on maps.

The Community Reinvestment Act was passed in 1977 to end this practice of “redlining,” by requiring banks to lend money in the communities where they are chartered to do business or receive deposits. Banks have made nearly $2 trillion in small-business and community development loans since 1996, according to our calculations, to meet the requirements of the law. That’s an impressive record.

But the law didn’t erase discrimination. Nor has it ended America’s glaring economic segregation, which is caused in part by unequal access to banking and credit. Three out of four neighborhoods marked “hazardous” by government surveyors 80 years ago are still lower-income today, according to our analysis.