A.M.
I.,
Was she a headbanger at all before? How are her language skills? Her developmental skills? Is she inconsolable during her tantrums? Is there any action you take that mitigates her tantrums or does she just go on and on no matter what you do? Does she fight you on "common" things like getting dressed, going to the grocery store,or any transition time (changing from one activity to the next)? Does she like to spin a lot?
The reason I am asking is my daughter did the same thing. It took me a year and a half but she was diagnosed with sensory processing disorder. It is on the autism spectrum. Headbanging is one of signs of the spectrum. That is not to say a lot of children not on the spectrum won't act this way but you should check with your Early Intervention(free county assessment, call you county and ask for the number). My daughter is in a lot of therapy and assistance now but she rarely headbangs anymore.
I took a lot of advice from everyone - tried everything from ignoring the behavior to punishment and even spanking which I do not believe in. Nothing worked because her brain does not process sensory input correctly.
I thought I would give you another option because I think you will get a lot of advice from mothers of typical children but if your daughter has SPD, it will all be completely useless. Please consider having her tested. I waited so long (on bad advice from friends and family)and the sooner therapy starts (if she has SPD) the better the outcome. Finally, in case she has SPD, it is NOT necessarily autism, it is its own diagnosis. Therapy consists of OT, developmental, speech, and behavioral but it really works. Your team will teach you how to handle her and you will see remarkable improvements in just months so consider this as an option.
Good luck to you.