Edward Robertshaw Hartley (25 May 1855–18 January 1918) was a British socialist politician.
Hartley began work in a mill at the age of ten, before becoming a warehouse clerk and then a butcher. He became an active socialist in 1885, in reaction to serious unemployment in his home town of Bradford. He was a founder member of the Bradford Labour Union and the Independent Labour Party (ILP). He stood for the party in Dewsbury at the 1895 general election, taking 10.4% of the vote, but was not elected. However, he did gain election to Bradford City Council that year, representing Manningham, and held his seat for over a decade. At the 1900 general election, he was nominated in Pudsey, but withdrew on the eve of the poll.
Hartley was intended as the ILP candidate for the Dewsbury by-election, 1902, with the support of the local trades council and the Labour Representation Committee, but the rival Social Democratic Federation (SDF) nominated Harry Quelch. Initially, neither candidate would withdraw, but the trades council convinced the ILP to drop Hartley's candidacy. Quelch did not gain the support of the local labour movement, nor of the ILP leadership. Angered by what he saw as pandering to the right-wing of the labour movement, Hartley actively supported Quelch's candidacy and joined the SDF. He founded a new SDF branch in Bradford, in 1904, and was elected to the SDF's executive for seven years, using the position to advocate socialist unity. Yet he remained part of the ILP group on Bradford Council, and was re-elected on the ILP ticket in Bradford Moor in 1905.