The Catrine Water System, once the world's largest water-powered system, is to be repaired with the help of the cash announced by the Heritage Lottery Fund (HLF).
Dating from 1787, it consists of a weir, five reservoirs known locally as "voes", a sluice gate, a fish pass and a 450-metre long tunnel.
The project, in Catrine, Ayrshire was state-of-the-art at the time. However, the weir has deteriorated, with sections in partial collapse and in danger of being washed away.
A community-led campaign to save it resulted in the HLF's involvement.
Colin McLean, head of the HLF in Scotland, said: "For almost 200 years, the Catrine Water System was central to the biodiversity and social history of the area as it brought with it jobs, housing and economic prosperity.
"This project demonstrates how history can be a living part of a modern community bringing people together to enjoy and benefit from their shared past.
"We recognise this community's passion and commitment to seeing their village regenerated through a celebration of heritage."
The Catrine Water System was built by landowner Claud Alexander and textiles entrepreneur David Dale as part of a cotton mill complex.
Two breastshot wheels, 50ft in diameter – the 'Lions of Catrine' – added in 1828 were the most powerful in the world and became a tourist attraction.
A new education centre will also be built on the site. Stuart Nelson, chairman of Catrine Community Trust, said: "This generous award virtually completes the £4million funding package that provides a much-needed boost to regenerate the village and provide employment."