The Western diet is rich in salt, which poses various health risks. A high-salt diet (HSD) can stimulate immunity through the nuclear factor of activated T cells 5 (Nfat5)-signaling pathway, especially in the skin, where sodium is stored. The kidney medulla also accumulates sodium to build an osmotic gradient for water conservation. Here, we studied the effect of an HSD on the immune defense against uropathogenic E.coli-induced pyelonephritis, the most common kidney infection. Unexpectedly, pyelonephritis was aggravated in mice on an HSD by two mechanisms. First, on an HSD, sodium must be excreted; therefore, the kidney used urea instead to build the osmotic gradient. However, in contrast to sodium, urea suppressed the antibacterial functionality of neutrophils, the principal immune effectors against pyelonephritis. Second, the body excretes sodium by lowering mineralocorticoid production via suppressing aldosterone synthase. This caused an accumulation of aldosterone precursors with glucocorticoid functionality, which abolished the diurnal adrenocorticotropic hormone-driven glucocorticoid rhythm and compromised neutrophil development and antibacterial functionality systemically. Consistently, under an HSD, systemic Listeria monocytogenes infection was also aggravated in a glucocorticoid-dependent manner. Glucocorticoids directly induced Nfat5 expression, but pharmacological normalization of renal Nfat5 expression failed to restore the antibacterial defense. Last, healthy humans consuming an HSD for 1 week showed hyperglucocorticoidism and impaired antibacterial neutrophil function. In summary, an HSD suppresses intrarenal neutrophils Nfat5-independently by altering the local microenvironment and systemically by glucocorticoid-mediated immunosuppression. These findings argue against high-salt consumption during bacterial infections.