As said before, it depends on your desination.
But even to the US they don't require it a the time of booking. For the US they only require your full name, gender, birth date and if you have a redress number. This is what is required during booking, because your travel agency or airline will not be able to issue the ticket without those details.
The passport data will be required only at check in. With most airlines you may be able to already enter them at the time of booking or online check in, but again: Only a few country require them. Not sure where you are flying to.
However, what could happen, is that they ask for your passport details during online checkin. LH
i.e. does this as soon as your flight is not a domestic or intra-Schengen-flight. This is not because they need to give this data to authorities, but to make sure that your passport is valid to travel without visa i.e.
Lets say you fly with LH
, then LH
might get a problem if you check in online. Then they will not be able to check your passport, and let's say you are i.e. from Serbia, then you would need a UK visa and LH
will be fined for having let you fly to the UK without a valid visa.
To make sure to avoid this they ask for your nationality, passport data and expiry date and so on during online checkin in order to make sure that in your specific case you have a valid passport (i.e. which is valid as least 6 months after the end of your travel for some countries). There is a big database behind that and if all is good LH
will write "DOC OK
" on your boarding pass. If you check in at the counter or check in kiosk then it will be checked by the kiosk or by an agent.