Bacteria must make their own folate. Sulfonamides block one step of that process.
Sulfonamides inhibit dihydropteroate synthetase, blocking bacterial folate synthesis. Examples are sulfamethoxazole and sulfadiazine. Co-trimoxazole combines sulfamethoxazole with trimethoprim and treats Pneumocystis jirovecii pneumonia. Non-antibiotic sulfonamides include sulfasalazine and sulfonylureas. Co-trimoxazole can cause hyperkalaemia, headache, a rash and, more seriously, Stevens-Johnson syndrome.