When petting a dog, it is generally best to avoid the head and instead pet the dog on the back or chest. Many dogs are sensitive about having their heads touched, and may perceive it as a threat. Instead, let the dog sniff your hand and then pet it gently on the back or chest. Avoid making sudden movements or loud noises that could startle the dog, and be sure to stop petting if the dog appears uncomfortable or scared.