Let's just say, touching someone's head is considered very rude, incredibly so if you're not family.
Head-patting among the younger generations (under the influence of foreign *cough*'murican*japanese*cough* culture) is slowly becoming the norm, though. Just don't do it in front of oldfags.
Also, you risk being labeled a pedophile.
(Speaking as a Thai)
No head pats! That's an insult!!ThaiSo cute.Apparently you should not pat children's heads in Thailand.
I heard it's true!