An easyJet flight carrying 167 passengers to the UK was one second away from disaster after the pilots misjudged the runway's length by almost a mile.
The Airbus A320 took off from Lisbon Airport
with just 110m (361ft) of tarmac remaining after the crew members used the wrong calculations for the runway they used.
Based on the speed it was travelling, in another 1.3 seconds the aircraft would have reached the end of the runway, according to a report by the Air Accidents Investigations Branch (AAIB).
"This could have caused significant damage to the aircraft and its occupants," the report said.
Before the flight to Manchester took-off on 16 September, the pilots carried out calculations for runway 21 at Lisbon Airport but mistakenly used the full length of the runway to make their assessment, according to the AAIB.
Instead, the pilots should have used measurements from the intersection on the runway which they used - a difference of 1,395m (4,577ft) from the full length of the runway, it added.
This meant that when the aircraft was cleared for take-off, the wrong calculations were used to get the plane airborne and threatened the safety of the aircraft, the AAIB said.
According to the report, the pilots noticed there was something wrong as they saw the red and white alternate lights of the last 900m (2953ft) of the runway but they did not select takeoff/go-around thrust.