The incident happened as a group of Asian men were passing Dewsbury Cemetery.
A car, believed to be a red Mini Cooper, pulled alongside the group and a woman inside the vehicle shouted abuse.
Supt Roger Essell, of Kirklees police, said: “This was an incredibly distressing experience and our enquiries are very much underway to identify those involved.
“The victims were understandably left shocked and upset following this incident.
“We take a robust stance against any kind of racial abuse.”
The incident happened between 10am and midday on Friday.
Witnesses should call 101, quoting crime reference 13170404287.