Thornton was born in Huddersfield in Yorkshire to tram driver Lewis Thornton and Selina, née Kerry. Selina left Lewis when Ernie was two, and after taking factory and building jobs Thornton was brought to Sydney by the Dreadnought Trust in 1924 and sent to the Government Training Farm at Scheyville. He was subsequently a construction worker and became a militant unionist. The Great Depression left him unemployed, and this led him to join the Communist Party of Australia (CPA). On 9 August 1934 he married Alice Mary "Lila" Felstead, née Curtis, who was divorced with two sons, at Collins Street in Melbourne.
Thornton was elected as an organiser in the Federated Ironworkers Association of Australia (FIA) in 1935. By 1936 he was part-time general secretary, and also a member of the CPA's central committee. Following the recovery of the economy in the late 1930s Thornton was made full-time general secretary and moved to Sydney.
Thornton's position in the FIA was threatened in the 1946 union elections when the Balmain branch, backed by the Labor Industrial Groups, ran a rival ticket headed by Laurie Short. Thornton won but Short took the case to the Commonwealth Court of Conciliation and Arbitration, which found that "persons unknown" had rigged the ballot, leaving Short as National Secretary. Thornton resigned in 1950 to become Australasia's representative at the World Federation of Trade Unions (WFTU) liaison bureau in Peking, but he was left without a job when the Australian Council of Trade Unions withdrew recognition of the WFTU. The FIA refused to accept him back and Thornton was employed full-time by the Communist Party.
A decline in party finances led to his return to manual labour as a crane driver, becoming honorary president of the Sydney branch of the Federated Engine Drivers' and Firemen's Association of Australasia. He died at Lidcombe in 1969 of myocardial infarction.