'Rag-Head' is considered to be marginal. Enough to prevent you from being hired, if blurted in a job interview, but not quite enough to get you fired, if blurted at a water cooler bull session.
Preferred usage is 'Towel-Head', unless there is a contextual implication that the towel was stolen from a motel room.
Other descriptive labels, such as 'Sand-Goblin', which do not refer to peculiar head ornaments, avoid this issue but may be in and of themselves 'questionable'.
Of course, it is always desirable not to refer to their religion as Islam-o-rama, or their highest holy season as 'Islama-ramma-damma-ding-dong'.
I hope that this has been helpful.