I have a bad toothache due to cavities, my head hurts bad and I feel dizzy sometime should I go to the hospital?

Seek help now. You have an infection. It,s spreading from the infected teeth to other organ systems. You need 1) root cal treatment or extraction NOW, not tomorrow or next week, and 2) medical support to deal with the infection related symptoms. Please seek help immediately. This will not self-cure.
Need more info. Decay can not only cause toothaches and headaches and facial pain; it can also have an effect on other parts of the body, including your blood pressure. The dizziness could be related to an elevated BP as well as from lack of nutrition and fluids if you are not maintaining an adequate intake due to pain when eating. You may want to talk with your primary care MD as well as your dentist.
Dentist/Hospital. It is hard to tell if your headache and feeling dizzy is from your cavities. If it is, you need to see a dentist. If your symptom is not from cavities, you may need medical attention. Either way, a visit to a dentist is a must, as cavities keep breeding harmful bacteria, which continue to infect your mouth, face, head, and body.