Saltpans are a class of ephemeral wetland characterized by alternating periods of inundation, rising salinity, and desiccation. We obtained soil cores from a saltpan on the Mississippi Gulf coast in both the inundated and desiccated state. The microbiomes of surface and 30 cm deep sediment were determined using Illumina sequencing of the V4 region of the 16S rRNA gene. Bacterial and archaeal community composition differed significantly between sediment depths but did not differ between inundated and desiccated states. Well-represented taxa included marine microorganisms as well as multiple halophiles, both observed in greater proportions in surface sediment. Functional inference of metagenomic data showed that saltpan sediments in the inundated state had greater potential for microbial activity and that several energetic and degradation pathways were more prevalent in saltpan sediment than in nearby tidal marsh sediment. Microbial communities within saltpan sediments differed in composition from those in adjacent freshwater and brackish marshes. These findings indicate that the bacterial and archaeal microbiomes of saltpans are highly stratified by sediment depth and are only minimally influenced by changes in hydration. The surface sediment community is likely isolated from the shallow subsurface community by compaction, with the microbial community dominated by marine and terrestrial halophiles.