Not actually true.
Lincoln supported his home state’s law, passed in 1853, forbidding blacks to move to Illinois. The Illinois state constitution, adopted in 1848, called for laws to “effectually prohibit free persons of color from immigrating to and settling in this state.”
To be exact