Urinary tract infections can go away on their own in time but if you suspect you have a urinary tract infection I recommend going to a doctor to get your urinary tract checked out in case something more serious is going on with your kidney's and urinary tract.
Having a urinary tract infection is something you shouldn't take lightly as it can lead to more serious problems down the road if left unchecked.