A watercolour by JMW Turner will return to public ownership and its home town in Wiltshire, it has been revealed.
Malmesbury Abbey, which was painted by Turner at the age of 52, has been acquired from a private collector by the Athelstan Museum in Malmesbury.
The £380,900 purchase was made possible by funding from the Arts Fund and National Lottery Heritage Fund.
Stuart McLeod, from National Lottery Heritage Fund, said it "now belongs to, and can be enjoyed by, the nation".
The 28cm (11in) by 41cm (16in) watercolour over pencil was painted in 1827.
It shows the abbey from the north on a summer morning, the foreground flooded with light and cattle warming themselves in the early sun.
Mr McLeod, said it can now be "enjoyed by, the nation for the first time in decades".
"It's incredibly exciting that its new home is Malmesbury, enabling people to see and explore this wonderful painting in the setting which inspired its creation," he said.
Sharon Nolan, from Athelstan Museum, said: "I am very proud that we have managed to save this watercolour for the nation and, more especially, that it is returning to its rightful home of Malmesbury."
The artwork is expected to go on display at the museum from late spring.
Turner, who was born in London in 1775, is considered one of the greatest figures in the history of landscape painting.