A growing number of airlines said they were avoiding Iranian and Iraqi airspace or flights to the region after Iran fired ballistic missiles against bases housing US troops in Iraq.

The US Federal Aviation Administration said it would ban US airlines from operating in the airspace over Iraq, Iran, the Gulf and the Gulf of Oman. 

"As a precautionary measure and following news of air strikes under way, Air France has decided to suspend until further notice all flights through Iranian and Iraqi airspace," an Air France spokesman said.

Iran launched a series of missiles at the bases housing US troops in the early hours, officials in Washington and Tehran said.

Iran's supreme leader later called it a "slap in the face" after a US drone strike killed Iranian military commander Qasem Soleimani near Baghdad international airport last week.

Shortly after the missile attacks, the US Federal Aviation Administration said it was banning US-registered carriers from flying over Iraq, Iran and the Gulf.

The region is an important corridor for flights travelling between Europe and Asia, although planes can be rerouted.

A KLM spokesman said: "Until further notice, KLM has no flights over Iranian or Iraqi airspace. All flights to different Southeast Asian destinations and other destinations in the Middle East will be flown through alternative routes."

In Germany, Lufthansa said it had cancelled its daily flight to Tehran in addition to halting overflights of Iran and Iraq until further notice.

It added that Saturday's twice-weekly service to northern Iraqi city Erbil would also not depart.

UAE carriers Emirates Airline and low-cost Flydubai said they had cancelled flights to Baghdad for "operational reasons".

Australia's Qantas said one of its London-Perth flights would be rerouted, with the other already flying an alternative route.

"We're adjusting our flight paths over the Middle East to avoid the airspace over Iraq and Iran until further notice," said a spokesman.

Both Singapore Airlines and Malaysia Airlines said they would divert flights from Iranian airspace.

Vietnam Airlines said it will make "appropriate adjustments" of routes to avoid areas of potential instability although its regular flight paths to Europe do not pass over Iran and Iraq.

Japanese airlines ANA and JAL, and Hong Kong-based Cathay Pacific said their planes do not fly through airspace affected by latest flare-up.