Headwalls are structures installed at the outlet of a storm sewer or culvert that function as a retaining wall to protect a roadway, railway, or developed property against erosion. In addition, headwalls are used to divert flow. Precast concrete headwalls and wingwalls are often specified with pipe and box culverts, and small bridges .