Occasional foam in the urine is normal and does not indicate a sexually transmitted disease, according to Mayo Clinic. A patient who has foamy urine regularly should see a doctor for further evaluation, as the foam may indicate protein in the urine, a sign of kidney disease.
Exposure to temperature extremes, strenuous exercise, fever and emotional stress can cause higher-than-normal protein levels in the urine, reports Mayo Clinic. Many different diseases, ranging from diabetes to sickle cell anemia, can also cause excess protein to form. A doctor can perform tests and make an accurate diagnosis for treatment of the underlying condition.