Hi, and thanks for your query on eHealth forum!
Back of the head area is called occipital area. This could be a case of occipital neuralgia. This usually happens due to spinal nerve compression because of overuse of computers, work involving straining of neck, herniated disc, canal stenosis, bone disease, spondylosis, poor posture. You should have a MRI focusing on C1-3 and also look at C1-2 instability.
A stiff neck due to muscle contraction can also cause occipital headaches. These can be treated with occipital nerve blocks. Since a confirmed diagnosis cannot be given on net please consult your neurologist to find the cause. Hope this helps. Take care!