Dear Sir,
The first step when you have pain is to check what are the factors that increase it and what relives it. Secondly visit a dentist, get the tooth checked and explain your symptoms. how they start and stop and since when you are having this problem. The dentist usually will take an Xray of that tooth and then give you a diagnosis and treatment plan. Your spontaneous pain may indicate need for some form of treatment like a Root Canal. The dentist who checks you os the best judge.
Next Steps
Visit a dentist, get a check up done and an Xray of that tooth.
Health Tips
Do not ignore the pain, get it checked immediately. Don't self medicate.