MD 77 begins at an intersection with MD 64 (Smithsburg Pike) in Smithsburg. The roadway continues northwest as county-maintained Leitersburg Smithsburg Road into the town of Smithsburg, where it becomes that town's Main Street, then continues northwest to
Leitersburg. MD 77's first intersection east of MD 64 is Wolfsville Road, which becomes
MD 17 at the Washington–Frederick county line and heads into the
Middletown Valley. MD 77 heads east as Foxville Road, a two-lane undivided road that passes through several sharp curves as the highway ascends South Mountain. The state highway passes Pleasant Valley Road before it reaches its highest point at the Washington–Frederick County line. East of Foxville, MD 77 begins to follows the boundary between Cunningham Falls State Park to the south and the
National Park Service-managed Catoctin Mountain Park to the north. Catoctin Mountain Park contains three historic camps:
Camp Greentop,
Camp Misty Mount, and the
Presidential retreat
Camp David. The MD 77 bridge over the Beaver Branch was constructed in 1928 and renovated in 2025. The state highway crosses the Monocacy River on a through truss bridge at Millers Bridge just south of the confluence of the Monocacy River and Double Pipe Creek. A short distance to the east, MD 77 crosses
Double Pipe Creek and enters Carroll County at the village of Detour, which is located just north of the confluence of Big Pipe Creek and Little Pipe Creek to form Double Pipe Creek. The state highway continues east as Middleburg Road, which intersects the Maryland Midland Railway at grade and crosses Big Pipe Creek before reaching its eastern terminus at MD 194 (Francis Scott Key Memorial Highway) in the village of Keymar, which sits at the junction of the Maryland Midland Railway's east–west and north–south rail lines. Middleburg Road continues east as a county highway that passes through
Middleburg and
Uniontown before continuing as Uniontown Road toward
Westminster. ==History==