Molecular chaperones are critical for protein homeostasis. In bacteria, chaperone trigger factor (TF) folds proteins co-translationally, and chaperone DnaK requires a J-domain cochaperone and nucleotide exchange factor GrpE to fold proteins largely post-translationally. However, when the pathogen Salmonella enterica serovar Typhimurium faces the infection-relevant condition of cytoplasmic Mg2+ starvation, DnaK reduces protein synthesis independently. This raises the possibility that bacteria differentially express chaperones and cochaperones. We now report that S. Typhimurium responds to cytoplasmic Mg2+ starvation by increasing mRNA amounts of dnaK while decreasing those of the TF-encoding gene tig and J-domain cochaperone genes dnaJ and djlA. This differential strategy requires the master regulator of Mg2+ homeostasis and virulence PhoP, which increases dnaK mRNA amounts by lowering the ATP concentration, thereby hindering proteolysis of the alternative sigma factor RpoH responsible for dnaK transcription. We also establish that DnaK exerts negative feedback on the RpoH protein and RpoH-dependent transcripts independently of J-domain cochaperones. Thus, bacteria express chaperones and cochaperones coordinately or differentially depending on the specific stress perturbing protein homeostasis.IMPORTANCEMolecular chaperones typically require cochaperones to fold proteins and to prevent protein aggregation, and the corresponding genes are thus coordinately expressed. We have now identified an infection-relevant stress condition in which the genes specifying chaperone DnaK and cochaperone DnaJ are differentially expressed despite belonging to the same operon. This differential strategy requires the master regulator of Mg2+ homeostasis and virulence in the pathogen Salmonella enterica serovar Typhimurium. Moreover, it likely reflects that Salmonella requires dnaK, but not J-domain cochaperone-encoding genes, for survival against cytoplasmic Mg2+ starvation and expresses genes only when needed. Thus, the specific condition impacting protein homeostasis determines the coordinate versus differential expression of molecular chaperones and cochaperones.