Two types of headaches that cause neck pain:
(1) Tension headaches
A tension headache is the most common. When someone has a tension headache, they may feel like a band is squeezing around their forehead, putting pressure on the head. The pain is usually all over the head. Some people also feel pain in the back of the neck and their shoulders when they have a tension headache.
People with high-stress levels often report having tension headaches. Poor posture and repetitive movements can also contribute to tension headaches.
There are two types of tension headaches. Episodic headaches often develop as a result of stress. Once the stressful situation is over, the headache usually eases up. Chronic headaches frequently occur, sometimes on a daily basis.
This is another common headache type. While the pain from a tension headache is often dull, migraines typically cause throbbing pain. The pain is usually located on one side of the head and might be in the neck, too. https://www.nhs.uk/conditions/tension-headaches/