Castle Rock is part of Stephen King's fictional Maine topography and provides the setting for a number of his novels, novellas, and short stories. Castle Rock first appeared in King's 1979 novel The Dead Zone, and has reappeared as late as his 2013 novel Doctor Sleep and 2014 novel Revival (see list below). The name is taken from the fictional mountain fort of the same name in William Golding's 1954 novel Lord of the Flies.
King, a native of Durham, Maine, created a trinity of fictional Maine towns – Castle Rock, Derry and Jerusalem's Lot as central settings in more than one work.
Population of Castle Rock was 1,280 by 1959 and around 1,500 as of its final chronological appearance in Needful Things. In Needful Things, Castle Rock is placed eighteen miles southwest of South Paris. In Creepshow (1982), there is a sign at the end of "The Lonesome Death of Jordy Verrill" that puts Portland at 37 miles, and Boston at 188 miles (it should be noted, though, that "Weeds," the short story on which "The Lonesome Death of Jordy Verrill" was based, was actually set in New Hampshire). Geographically, this puts Castle Rock in the northern semicircle, of radius 37-miles, centered on Portland, Maine. This could include places such as Durham, Lisbon, Danville, Auburn, Lewiston, Bridgton, and maybe even Sabattus. A map on King's official website places Castle Rock in Oxford County, in the vicinity of . Yet the works in which Castle Rock appears place the town in the fictional "Castle County," which also includes such towns as Castle Lake and Castle View.