Maryland Route 31 (MD 31) is a state highway in the U.S. state of Maryland. Known for most of its length as New Windsor Road, the state highway runs 16.95 miles (27.28 km) from MD 26 in Libertytown east to MD 140 in Westminster. MD 31 connects the county seats of Frederick and Westminster via Libertytown in eastern Frederick County and New Windsor in western Carroll County. MD 31 originally extended from Frederick to Manchester, using the paths of what are now MD 26 and MD 27. MD 26 assumed MD 31 west of Libertytown in 1933 and MD 27 took over MD 31's route north of Westminster in 1967. The Westminster–Manchester portion of the state highway was constructed as one of the original state roads in the early 1910s. The remainder of the highway was built in the early to mid-1920s. MD 31 was rel