First of all, we should remember that for most of the "mid-1800s" (however one defines this) African Americans in the South were mostly enslaved rather than simply suffering discrimination. However, even those African Americans who were not enslaved were discriminated against.
There are many examples of this discrimination. Free blacks in almost every state (even in the North) could not vote. In much of the South, it was illegal to educate any African American, even ones who were free. Many states had laws that allowed African Americans to be enslaved as punishment for crimes. This was not something that could be done to whites.
In these and other ways, blacks were discriminated against even if they were free.
During the 1800s, the pressure by the whites to establish racial supremacy led to a variety of discrimination against African Americans. African Americans lost their rights to citizenship, they were barred from voting, barred from working in skilled jobs, and their participation in juries was revoked. These forms of discrimination occurred predominantly in the South. This situation forced the African Americans to migrate to the North, where although slavery was not popular, they were still not free men. In the North the African Americans were subjected to segregation, they were not allowed in public transportation, churches, schools and even entertainment halls. African Americans were not allowed to vie for elective posts and while in some states their rights to vote were completely revoked, in others, the situation was made difficult for them to exercise their basic rights. The Black society lived under constant threat of violence, throughout the period.