Thanks for posting your query.
Conditions you have described refers to one of possible cause that is Gout.Gout is a kind of arthritis
caused by too much uric acid in the blood. It can cause an attack of sudden burning pain, stiffness
, and swelling in a joint, usually a big toe.You can also get gout attacks in your foot, ankle, or knees.
It can be related to Obesity,alcohol,meat and seafood,kidney disease, thyroid disease
or certain drugs.
You should consult your doctor and get uric acid levels done, aspiration of fluid from joints may be required to rule out the condition.
You can take acetaminophen/ asprin for pain. Once gout is diagnosed it can be treated with Colchicine
Hope it helps.