Davis was born on April 18, 1864 in Philadelphia, Pennsylvania. His mother Rebecca Harding Davis was a prominent writer in her day. His father, Lemuel Clarke Davis, was himself a journalist and edited the Philadelphia Public Ledger. As a young man, Davis attended the Episcopal Academy. In 1882, after an unhappy year at Swarthmore College, Davis transferred to Lehigh University, where his uncle, H. Wilson Harding, was a professor. While at Lehigh, Davis published his first book, The Adventures of My Freshman (1884), a collection of short stories. Many of the stories had originally appeared in the student magazine the Lehigh Burr. In 1885, Davis transferred to Johns Hopkins University.