He died of strangury on 20 July 1819, and although an eminent man was buried in an unmarked grave in Old Calton Burial Ground, on Waterloo Place in Edinburgh. His, and his brother, James's graves were marked by a plaque unveiled in 2011 following a local campaign. The monument to his memory by William Henry Playfair, on Calton Hill, is visible from the spot.