MacLellan's Castle in the town of Kirkcudbright in Galloway, Scotland, was built in the late 16th century. It is located in the center of Kirkcudbright, on the south side of the Dee River, which flows into the Solway Firth. The Castle of L-plan is the residence of the MacLellan family and is named after it. The family has sold the Castle in 1752, and it was held by the Earls of Selkirk from 1782 to 1912. Today, the site is planned by the Scottish Historic Environment Organization.