Robert Machray (May 17, 1831 – March 9, 1904) was an Anglican bishop and missionary and the first Primate of the Church of England in Canada (now called the Anglican Church of Canada).
He was born in Aberdeen, Scotland. He was the son of Robert Machray, and wife Christian Macallum.
Machray was educated at King's College, University of Aberdeen and Sidney Sussex College, Cambridge, where he studied mathematics, philosophy and theology.
He was ordained in the Church of England in 1855 and served parishes in that country, as well as serving as dean of his alma mater at Cambridge. In 1865, he became Bishop of Rupert's Land (in Canada), becoming archbishop of the province when his diocese was split in 1875. At the first General Synod of Canadian Anglicans in 1893 he was unanimously elected as the first Primate of All Canada, serving in the position until his death. In 1893, he was appointed a Prelate of the Order of St Michael and St George. On 9 March 1904, he died unmarried at Winnipeg.