Ayn Rand saw collectivism in all its forms as an impediment to human rights. "The good of society" cannot be the basis of rights, since society is merely a collection of individuals, and so the only proper rights are individual rights. When we base rights on what is good for society, that begs the question: Who speaks for society? Throughout history, such people who claim to speak for society inevitably turn out to be tyrants. You have a few, even a single person, deciding what is good for the people. Rand thought that people ought to decide for themselves, based upon rational self-interest.
Racism, as a collectivist pursuit, was anathema to her strictly individualistic Objectivism. To her, all forms of collectivism be they socialism, fascism, or racism were immoral on the basis that collectivism on the national level, ultimately and inevitably leads to authoritarianism and the trampling of individual rights by the government. Racism therefore, would necessitate that same authoritarian brand of government that all other forms of collectivism required in order to sustain itself on a national level.