Members of the European Parliament have approved a directive whereby airlines will pass passenger information, via the passenger name record (PNR), to the authorities.
The information is for passengers flying to and from destinations outside the EU although it could be extended to flights within the EU as well.
The issue has been on the agenda for some time in light of terrorist attacks but it has been difficult to achieve common ground especially around issues of data privacy. A provisional agreement was however reached last December.
A statement on the directive says airlines will have to provide the information in order to "help authorities flight terrorism and serious crime."
The data will be kept for five years but after six months details such as names and addresses will become anonymised.
The directive was adopted this week by MEPs by 461 votes to 179 and individual EU countries now have two years to bring it into force.
In the statement, Timothy Kirkhope, of the European Conservatives and Reformists and the rapporteur for the proposal says:

"We have adopted an important new tool for fighting terrorists and traffickers. By collecting, sharing and analysing PNR information our intelligence agencies can detect patterns of suspicious behaviour to be followed up. PNR is not a silver bullet, but countries that have national PNR systems have shown time and again that it is highly effective.”
He adds that there are safeguards within the directive regarding the collection and storage of personal data.
As part of the directive, member states will set up 'Passenger Information Units' to collect and store the PNR data and transfer it to the authorities. These PIUs will also exchange the data with other member states.
However, the data transfer is on a case-by-case basis and only for the purpose of preventing terrorism and crime.
A further provision enables EU countries to "choose to collect and process PNR data from travel agencies and tour operators" because they are also involved in booking and processing passengers.
NB: Here's a clip on the issue with some for and against views.