Cadmium is recognized as one of the most toxic heavy metals, and chronic cadmium exposure threatens plant, animal and human health. Because certain bacteria can play an important role in remedying heavy metal pollution, it is essential to further our understanding and clone cadmium adsorption and resistance genes from microorganisms. In this study, the cadmium resistance of different Escherichia coli strains including BL21 (DE3), JM109, DH5a, Top10 and Mach was determined. Among those strains, the E. coli BL21 (DE3) exhibited the highest cadmium resistance. Sequence analyses of four cadmium resistant clones screened from the BL21 (DE3) fosmid library showed that the insertion of each fosmid plasmid contained a fragment located at the lambda phage DE3 region. Next, we overexpressed several genes of this fragment in BL21 (DE3) and identified that cadmium resistance of E. coli is acquired through the capB gene. Indeed, overexpression of the capB gene increased the adsorption rate of cadmium. Taken together, these results indicated that the capB gene confers E. coli BL21 (DE3) with increased cadmium resistance by adsorption of cadmium. This study provided new insight into the mechanism of microbial cadmium resistance and expanded our understanding of cadmium resistance, adsorption and bioremediation by microorganisms.