TMZ/Getty
Exclusive Details

American Airlines Flight Makes Emergency Landing ... Something's Stinkin' Up the Cabin!!!

Everyone onboard an American Airlines flight smelled it -- that much we know -- but the problem is they had no clue who or what dealt it, so the pilot was forced to make an emergency landing.

The Wednesday night flight from Miami to Barbados was inundated by the pungent chemical odor -- and because the crew believed it was coming from a passenger's carry-on bag, you can imagine the panic that caused.

The pilot made the quick decision to head back to the MIA.

Miami-Dade Fire Rescue units met the plane once it landed, and all 172 passengers were quickly evacuated as firefighters investigated.

Sources with direct knowledge tell TMZ ... the smell was coming from a large, industrial-strength bottle of nail polish -- it somehow made it through TSA and spilled in the passenger's bag. We're told the woman isn't in any trouble.

The airline reported some of the crew members on board were feeling sick from the odor ... and went to a hospital out of extreme caution.

Click here for info about our online advertising practices.