Phosphorus is a key component of both ATP and DNA because of their phosphate groups. DNA has one phosphate group with four molecules of phosphorus each per nucleotide. ATP is made up of three phosphate groups with four molecules of phosphorus per each group. While carbon is a good answer, the best answer that specifically pertains to both DNA and ATP is phosphorus.