When visiting alien or foreign cultures, some amount of Culture Clash is inevitable. In fiction, writers are able to take this to almost ridiculous extremes and milk the resulting dramatic tension.
Here's the basic formula: take a society. Give them, as one of their hats, a rigid and/or complex code of manners or tradition they adhere to. Make the consequence of breaking that code dire: death, slavery, imprisonment, declaration of war, loss of a desperately needed supply or alliance they have. Insert the protagonists, usually well meaning but likely to have difficulty complying. If they can get away with asking why the punishment is so severe, the response will often be "What Do You Mean, It's Not Heinous?" Or if the custom is particularly lacking in good sense from the outside point of view, well, "Nobody Ever Complained Before." Shake well and watch your protagonists squirm.
If the members of the culture in question are hip to the fact that outsiders are prone to stumbling on the rules, they may be nice enough to give a warning or two before bringing the hammer down. Probable good ending: both cultures learn to understand each other better and An Aesop is learned about respecting other's differences. Probable bad ending: the crew has to rescue one of their own and make a break for it with the angry mob on their heels.
A Sub-Trope of Culture Clash. Super-Trope to Fumbling the Gauntlet, where the character's innocent action is taken as a challenge to fight. See also: Planet of Hats, Sacred Hospitality and Peace Pipe. Likely to involve invoking the Alien Non-Interference Clause. Not to be confused with Prestige Peril.
- RainbowDoubleDash's Lunaverse: The main characters have a bad habit of mouthing off toward heads of state, or worse, when they meet them (like Lyra criticizing the head of an extremely paranoid nation for his country's very, very racist notions). Except, funnily enough, for Trixie, who's the only one of the six with prior knowledge of statesm-... err, statesponyship, who's usually trying to get everyone else to stop talking before they have someone else out for their blood.
- The Cascadians of Vatta's War put a huge emphasis on politeness over much else and the list of things that are considered impolite is vast. Visitors to the spaceport are given a sizable booklet explaining the rules and expected to learn them. The third book has Cpt. Kylara Vatta in a courtroom defending her identity against another Vatta starship captain claiming she is an imposter; being found in contempt of court is an offense that carries the death penalty. When DNA tests show the other captain was lying, he gets aggressive and insulting and having already been warned, is found in contempt. This does not sit well with Ky, even though he's been shown to be in league with the organization that murdered her family.
- Arabian Nights: In Arabian cultures it is taboo to eat with your left hand; one man who tries it gets it cut off by his dinner guest. In another tale this becomes an issue for a man who lost his right hand...
- The Retrieval Artist series by Kristine Kathryn Rusch has the Earth Sphere Alliance bound by treaties with their alien trading partners to honor their laws and extradite people who break them, with judgements handed down by a Multicultural Tribunal. Many of the alien crimes, punishable by death or Fate Worse than Death, are acts that would be completely innocent in the eyes of humans - say, stepping on the wrong sort of plant. This is why there are agencies to Disappear people who run afoul of them, trackers that hunt them for the law and retrieval artists working outside the law who may bring them back for other reasons.
- Isaac Asimov's short story Strikebreaker features a little colony in an asteroid. Being so small everything must be recycled, even water, from feces. Naturally someone has to do the job and the asteroid's inhabitants try to make him as comfortable as possible. However, it's stigmatized by everybody, who due to social prejudice avoid interacting with him and feel physical disgust by him. The trouble appears when an outsider arrives at the colony to make social studies.
- To the humans in the Foreigner 'verse, The War of Landing was caused by this — everything was going wonderfully until suddenly the atevi attacked them. To the atevi, they spent years trying to negotiate their way out of the war before finally being pushed too far.
- The wretched beast-men of The Island of Doctor Moreau adhere to a rigid set of rules intended to prevent them from backsliding into animalistic behavior. Any of their number who violate these rules is harassed by the others and hauled back to Moreau's "House of Pain" for surgical re-modification, and the novel's human protagonist is expected to conform to the same rules.
- In Dune, this almost happens when Duke Leto's entourage meets with Stilgar, a Fremen leader, for the first time. As Stilgar walks out, he spits on their table. Some of the men react with anger, but fortunately Duncan Idaho, who is familiar with Fremen customs, is on hand to explain: water is so precious a resource on Arrakis that every drop is counted and precious, and the Fremen wear suits that recycle 100% of a body's waste water. To share one's bodily water (as with the spit) with someone else is therefore a gesture of great respect.
- The Tamuli: The Atan Proud Warrior Race have such an unforgiving code of honour that they volunteered to be nominally "enslaved" to the Tamul Empire in order to Defy the trope. Ehlana's bodyguard Mirtai once explains that, had she not been "owned", she would have been honour-bound to kill every man who insulted her by letting his shadow fall on her, among many other incomprehensible offenses.
- Star Trek thrives on this trope:
- In The Next Generation first season episode "Justice", the crew beams down onto a seemingly pleasurable planet inhabited by the friendly Edo, where it is explained that no one breaks the rules because of random inspections and only one punishment: execution. Then Wesley, who was playing with other kids, accidentally breaks a greenhouse window and it just so happens that's where the moderators check at that moment...
- "The Big Goodbye" has Picard practicing the language of an alien race on the holodeck to prepare for upcoming delegations, because the slightest mispronunciation will be taken as a grave offense.
- There's an episode of Star Trek: Voyager where B'Elanna (part Klingon) gets arrested for having violent thoughts on a planet of telepaths.
- Janeway once nearly ruins relations with a species called the Tak Tak. Apparently to them, putting one's hands on one's hips is the greatest insult possible. Well, body language is a major part of their language. We can get by without it, but they can't.
- Star Trek: Enterprise:
- The crew of Enterprise once manages to anger alien dignitaries by having a dinner in their honor. This is highly offensive to the visitors (whose hat is already "easily offended") because on their planet you eat alone. "You eat like you mate!"
- Then there is the one where Captain Archer brings his dog along to a meeting with those same aliens because they have some critical parts for Enterprise. Porthos promptly marks a sacred tree and angers the aliens. Archer starts raging about this once he's back on the ship and says he'll piss on their tree himself. This is the episode that also establishes that Archer is a trained diplomat.
- Stargate SG-1:
- In "Emancipation", Carter speaks to a man on a Mongol-influenced planet and is immediately sentenced to death. Fortunately, she has just saved a man's life, though, so she is spared.
- Vala is burned alive on an Ori planet for swearing. Well, that is only after they realize she has no idea how to perform the daily religious ceremony that the person she is currently inhabiting should have known. They take it as a refusal and thus brand her as a heretic.
- JAG: The main story in "Head to Toe" is about a female Naval Aviator who refuses to wear the abaya and show deference to the locals while stationed at a U.S. Air Force base in Saudi Arabia.
- The Traveller Adventure, segment "Pysadian Escapade". While their PC's are on the planet Pysadi, the players are railroaded by the referee into having the PC's take on a group of anolas (alien animals) as pets. When the Pysadians find out about this violation of their religious laws, they imprison one of the PC's as a companion for the anolas and expel the other PC's from the planet.
- Fairly common in Legend of the Five Rings, being based in a Fantasy Counterpart Culture of samurai-era Japan with a vast number of strict social protocols. (Depending on the circumstances, you can get gigged for following too strict of a protocol.) Players are encouraged to try to remember, but the Etiquette skill can be used to see if they remember the precise courtesy for their situation. It's also used as a "social defense" roll to prevent others from gaining an advantage in social conflicts.
- This trope was the cause of the Terran-Vasudan War in FreeSpace. For clarification, the Vasudan language is ridiculously complex and changes depending on things like your relative status to the other person, the time of day, your spacial position relative to the Emperor, etc. The translator (no word on whether said translator was human, Vasudan, or machine) screwed up somewhere during first contact and it all went south from there.
- Subverted in Star Control II where it was previously thought that the war with the VUX was the result of the captain of the First Contact ship calling the VUX captain ugly. Turns out, they are the ones who think we're too ugly to be left alive and simply used the accidental insult as a pretext.
- Mass Effect:
- Mentioned to be a bit of an issue with the hanar, whose culture places extraordinary importance on being polite. Hanar that travel off-world and expect to deal with people from other species routinely go through a form of special training, learning to not take offense as easily as they would on the homeworld because the other species are not going to be as polite.
- This marks the big problem the Citadel Council has with the culture of the yahg. The yahg have a strong pack mentality: if a group of yahg forms to work together, they will compete with one another until one of them arises as the dominant leader. When the Citadel sent a group of diplomats to facilitate first contact, the yahg were extremely insulted by the idea of the other species wanting to speak to them as equals, and slaughtered the group for their disrespect (the fact that the diplomats were politicians, and the yahg are extremely sensitive to body language and could sense duplicity on them, did not help either). The Council declared the yahg homeworld under quarantine and all further contact with the species was cut off.
- A Magical Roommate has an off-screen moment where Kuralla visits one of the fairy lands and accidentally performs the wrong bow. The king makes her and Sages leave in exchange for him doing nothing else.
- Homestuck has the trolls who, due to differences in reproduction, results in buckets in the troll world being viewed the same way that pornography would be viewed by an individual from our world. Therefore, Hilarity Ensues whenever buckets come into play.
- The "Where the Buggalo Roam" episode of Futurama features native Martians as Native American stereotypes. There is a misunderstanding, but it will all be OK as long as Kif doesn't cough while smoking the Peace Pipe. He does. The punishment is death.
- Rocky and Bullwinkle: Mr. Peabody and Sherman visit a historic old west settler who cannot leave an Indian village because he does not know the Indian word for "goodbye." Mr. Peabody tells him what it is, but his poor memory has him screw it up and insult the Indians.
- In the King episode "The Museum of Tomorrow", Russel has to find out a crime that he will commit. Turns out that he managed to anger aliens by messing up their meeting ritual which involves kicking each other in the shins causing them start destroying the kingdom.
- My Little Pony: Friendship Is Magic: Ember the dragon stumbles into a few cultural misunderstandings when visiting Ponyville in "Triple Threat".
- First, when unicorn trumpeters welcome her with a fanfare, she covers her ears in pain and gets into a hostile stance in response, clearly believing she's under attack, until Spike distracts her.
- Later, as part of a bombastic dragon-style greeting, she breathes fire toward the sky, which scares all the ponies around. She says that usually, when she does this, other dragons are eager to meet her.
- When the explorer Vasco da Gama came round Africa for a First Contact with the Indian Grand Mogul, his ships were loaded with beads for trade and diplomatic presents because that was sufficient for the low tech cultures along the way. Unfortunately the Grand Mogul had a technology base about equal to Europe and ruled one of the richest parts of the world. Naturally he wasn't pleased at having beads as a gift.
- A relatively mild example often ensues for new recruits joining the military, particularly in more individualistic cultures where one isn't accustomed to taking orders from arbitrarily appointed superiors and having to place the group before themselves. Not to mention little things like proper forms of address. A group session of Physical Fitness Punishment is not only to be expected, but pretty much designed into many such training regimens.
- The one recruit getting chewed out for calling his drill sergeant "Sir" or failing to call an officer "Sir" is pretty much a stock trope in military settings.
- During the Vietnam Wars, CIA and other intelligence agents undercover as officers were known to mistakenly salute enlisted men and NCO's or address them as "Sir". One would wonder why they weren't properly briefed on military protocol, unless they were set up for failure to amuse the more senior agents.