For UTIs, a doctor might give you antibiotics. These can include trimethoprim/sulfamethoxazole, nitrofurantoin, or ciprofloxacin. The right one depends on which bacteria has caused the problem.