Grandfathered in is a phrase from the ugly post-Civil War Jim Crow era in the Deep South that refers to efforts to legally protect the rights of White people while denying newly freed Blacks voting rights.They passed a law saying illiterate people couldn't vote knowing most newly freed slaves were illiterate because it had been illegal for slaves to learn to read. They then added a clause saying "You can still vote even if you are illiterate if your grandfather could vote."This meant dirt poor illiterate White people were likely to qualify for the right to vote but no newly freed slaves would pass this test granting an exception for illiterate Whites. Their grandfathers were likely slaves (or rapey White slave owners not admitting to being the father, but that detail is something newly freed slaves were unlikely to argue in a court of law at that time).
That's from a piece called Rotten to the Core on Eclogiselle and you may wish to read it because it says more than that about the use of the term. These days, the term grandfathered in seems to be most commonly used in real estate and I think a lot of people don't know the ugly origin of the term.
Jim Crow laws often explicitly denied people of color rights because they were people of color but this one used proxies to deny Blacks the right to vote while protecting the voting rights of poor, illiterate Whites.
If you don't know the context that slaves were not only not provided education, it was illegal for them to learn to read in many US states, it's not obvious that this law is a racist law intended to deny rights to Blacks while protecting Whites. And I suspect many people don't really get that given the popularity of letters supposedly written by former slaves.
And it's more complicated than that because everyone knows White slave owners fathered children on Black slaves yet defacto denied being the father and we have a concept of The One Drop Rule where if you have ANY African ancestry you are absolutely NOT White.
But I have never heard that anyone challenged this particular law in court by saying "Technically, my grandfather was White and literate because my grandmother was impregnated by her owner."
Anyway, this isn't really intended to be a history lesson. It's a post about vocabulary, so I will stop there.