If Airlines Banned Smoking, Why Do New Airplanes Still Have Ashtrays?

It's a prototypical in-flight brain teaser - which comes on with the dusk and soon vanishes as the wheels touch the ground at dawn.

If smoking is legally banned in the aircraft's, what for are the ashtrays?

It's required by the law.

According to title 14 of the Code of Federal Regulation (CFR) Chapter  I, Sub Chapter C, Part 25, Sub Part D, Section 25.853 and Paragraph g, "regardless of whether smoking is allowed in any other part of the airplane, lavatories must have a self-contained, removable ashtrays located conspicuously on or near the entry side of each lavatory door, except that one ashtray may serve more than one lavatory door if the ashtray can be seen readily from the cabin side of each lavatory served."

If more than 50% ashtrays are broken or not in a condition to be used than they should be repaired within 72 hours i.e. 3 days.

This law was decided by some very clever person who thought that it's not at all a good idea to have flammable substances on any vehicle which is approx 37,000 feet above the ground and full of jet fuel.

In 1973, an aircraft travelling from Ria De Janerio to Paris had to make an emergency landing because the aircraft cabin was filled with smoke. This lead to the death of 123 people and survival of 11.

The root cause of this incident was a CIGARETTE.

There was a possibility that a cigarette must have been put in a waste paper bin in the craft's toilet, which afterwards led to smoke in the aircraft.

As a result, US Airlines started banning cigarettes in 1988 for some flights (within the duration of 2 hours). By the end of 1990, all the domestic flights were smoke-free (within the duration of 6 hours). And since 2000, smoking on the aircraft has been banned internationally as it is an essential safety feature.

Therefore, ashtrays are not there in the aircraft as an invitation to the smokers. Rather, they are there as the FAA does not trust the people.

This is the basic reason why ashtrays are still there in an aircraft i.e.as a precautionary measure.