A flight could have been just seconds away from crashing into the ground after an incorrect autopilot setting caused the plane to plummet, an investigation has recently found.

Some 44 passengers and four crew were on-board the Flybe flight from Belfast City Airport to Glasgow when the plane nosedived 498 feet in 18 seconds shortly after takeoff on January 11.

A report by the Air Accidents Investigation Branch (AAIB) said that the autopilot was engaged when the Bombardier Dash 8 Q400 turboprop plane reached an altitude of 1,348 feet.

The aircraft continued to climb to 1,500 feet but then “pitched nose-down and then descended rapidly” because autopilot was mistakenly set with a target altitude of zero.

Cockpit alarms alerted the captain and first officer to what was happening.

They later reported they had “become visual with the ground.”

The captain disconnected the autopilot and recovered the aircraft, having dramatically dropped to 928 feet.

The maximum rate of descent of 4,300 feet per minute during the event suggests the aircraft may have hit the ground just a few seconds later if the crew had not intervened.

Luckily the flight was recovered and continued on to land safely at Glasgow Airport.

The AAIB concluded that the crew’s selection of a particular autopilot mode before takeoff led to the zero altitude target.

Autopilot systems are used to automatically control aircraft.

Flybe has taken several safety measures in response to the incident, including revisions to simulator training and amendments to pilots’ pre-takeoff checklists.

A spokeswoman for the airline said: “Flybe maintains a rigorous approach to ensuring the very highest flying standards are maintained.

“As reported by the AAIB, Flybe implemented remedial actions quickly in response to the incident and our training and procedures have been amended to minimise the risk of a reoccurrence.

“Flybe operates over 158,000 flights a year and the safety of our passengers and crew remains our number one priority.”

This story originally appeared on The Sun. Read more content from The Sun here.