Yes, “gypsy” is a racial slur.
Here’s a good article on the subject.
Basically, ignorant people labeled another group of people (the Roma) “gypsies” because they thought they looked like Egyptians, and therefore must have been Egyptians. These same people treated them like crap. Today, the word “gypsy” is loaded with negative stereotypes - in fact, the word “gip” or “gyp” (which means “to con” or “to cheat”) comes from the word “gypsy.”
And that’s what makes a slur.
Edit: The page I linked to originally is now gone, so please refer to this and this instead.