The bacterial H-NS protein silences expression from sequences with higher AT-content than the host genome and is believed to buffer the fitness consequences associated with foreign gene acquisition. Loss of H-NS results in severe growth defects in Salmonella, but the underlying reasons were unclear. An experimental evolution approach was employed to determine which secondary mutations could compensate for the loss of H-NS in Salmonella. Six independently derived S. Typhimurium hns mutant strains were serially passaged for 300 generations prior to whole genome sequencing. Growth rates of all lineages dramatically improved during the course of the experiment. Each of the hns mutant lineages acquired missense mutations in the gene encoding the H-NS paralog StpA encoding a poorly understood H-NS paralog, while 5 of the mutant lineages acquired deletions in the genes encoding the Salmonella Pathogenicity Island-1 (SPI-1) Type 3 secretion system critical to invoke inflammation. We further demonstrate that SPI-1 misregulation is a primary contributor to the decreased fitness in Salmonella hns mutants. Three of the lineages acquired additional loss of function mutations in the PhoPQ virulence regulatory system. Similarly passaged wild type Salmonella lineages did not acquire these mutations. The stpA missense mutations arose in the oligomerization domain and generated proteins that could compensate for the loss of H-NS to varying degrees. StpA variants most able to functionally substitute for H-NS displayed altered DNA binding and oligomerization properties that resembled those of H-NS. These findings indicate that H-NS was central to the evolution of the Salmonellae by buffering the negative fitness consequences caused by the secretion system that is the defining characteristic of the species.