A urinary tract infection, or UTI, happens when the urinary tract becomes infected, usually by bacteria.