In many countries, poverty is highly correlated with race, for example. This is certainly the case with the US, but also elsewhere. I live in London, and you see interesting effects of this.
The inner city boroughs are quite segregated, both by race and wealth.
Meanwhile, some of the outer boroughs are showing the reverse effect, where property price points appears to be a driver for mixing. E.g. Croydon, where I live, is one of the most mixed in London - it's at a price point that creates both young professionals of all races, and more established families of all races who are united in finding the inner boroughs either too expensive or too poor.
But overall: Imagine that nobody had a racial preference, but had a wealth preference - and limitations.
Now to overcome segregation, you face a near insurmountable barrier: Wealthier people would need to be willing to settle for housing and an environment of a much worse standard than they can afford, and poorer people would be unable to find housing that makes much difference.
This is one of the biggest problems. The recent US situation with demonstrations over police killings, the race aspect has been blown out of proportion: You don't solve anything by focusing on the race issue, because so much of the violence is correlated more strongly with poverty than with race. You want to solve racial issues, start by addressing poverty. You'll still have race issues at the end of it, but it will turn out vastly smaller than what it appears, and you'll have removed a substantial source of excuses for racial biases.