Passengers were first instructed to move to the other side of the train in an attempt to transfer the weight of the carriage away from the man’s leg.
When this failed, passenger Nic said everyone was told to exit the train.
About 50 passengers were then lined up alongside the carriage and told to push, Nic said.
“We were able to move the train quite a bit,” he said. “The train moved 5-10cm on its suspension, which was enough to free his leg.”
St John Ambulance paramedics attended the incident but the man was not required to be taken to hospital.
Nic said the man was walking freely after the incident, which caused a 15-minute delay on the Clarkson line.
He commended the way in which Transperth staff coordinated the rescue effort.
Transperth spokesman David Hynes thanked the passengers involved in the rescue and congratulated the staff for their quick thinking.
“We hear a lot about poor behaviour on public transport. It’s really great when something like this happens and people work together to help a fellow commuter.”