The eponymous demihuman warriors of Claymore are sworn never to kill a human under any circumstances on pain of being hunted down by their colleagues (presumably to keep the general populace at least a little less frightened of them than the creatures they hunt). In practice their behaviors range from refusing to raise a hand against any human to avoiding deathblows and making sure nobody bleeds out to slaughtering any witnesses to prevent accusations from being made.
Mermaid Melody Pichi Pichi Pitch's forbidding of relationships between mermaids and humans. Legend even stated that if a mermaid revealed her identity to a human, she would die, although the manga, at least, seems to show that this is not in fact true by introducing Hamasaki, a human with a known mermaid ancestor.
In Sailor Moon, Sailor Pluto had three taboos: she was forbidden to leave the Space-Time Door, to bring others through it, and to stop time (it was said that using her power to stop time would result in her death). Nevertheless, she broke all three directives in both the anime and the manga and got away with it, although she stopped time under different circumstances (in different Story arcs, even) and seemed to die immediately afterward, then came back with little explanation.
In Tantei Gakuen Q, DDS students are not to parade their identity. Nonetheless, they whip out their notebooks whenever they hit a slight snag in operations and sometimes before then - and as of episode 34, it's only seriously backfired once.
In Haruhi Suzumiya, Yuki Nagato's directive is to "observe and not interfere." She's violated that directive quite a number of times by book 10 of the light novels and will probably continue to do so for the near future.
Similarly, the Watchers from Marvel Comics have a non-interference oath that exists pretty much so that Uatu can break it, thereby establishing that the stakes are really high this time.
The Watchers are very strict about their Prime Directive most of the time. In one case the universe was being destroyed and the Watchers (an entire race of people with power rivaling Galactus) went to watch the show.
Deconstructed in Earth X, where the Watchers' oath turns out to exist so they can weasel out of preventing (and emotionally distance themselves from) the multiple genocides committed by their masters, the Celestials as the latter carry out their plan to take over the universe. Uatu's violations are also explained- he only ever interceded when the fate of the world (literally, as he was out to protect the Celestial gestating inside Earth) was at stake.
Lampshaded by a Celestial that the Watcher has broken his oath over four hundred times. Though for an immortal being that's lived billions of years, theoretically that means he doesn't violate it all that often.
In Star Wars, the Sith have an ages-old rule that there can be only two Sith at any given time — a master and an apprentice. They break this rule all the time, especially in the Expanded Universe, in which every villain from the movies seems to have two or three "secret apprentices." Granted, they're villains, so rule-breaking is no surprise, but it makes you wonder why they made this dumb rule for themselves in the first place.
A lot of these make the Dark Side = Sith distinction. You can teach the force to others, but Sith Techniques are shared only between a Master and Apprentice. Of course a lot of Sith have broken this one too.
Similarly, the Jedi have their own creed, though never specifically stated in the movies. The promotional material for Episode II told us that "A Jedi Shall Not Know Anger. Nor Hatred. Nor Love". And in the Expanded Universe, the Jedi Code taught is:
There is no emotion; there is peace.
There is no ignorance; there is knowledge.
There is no passion; there is serenity.
There is no death; there is the Force.
While many Jedi seem able to more or less come to terms with anger and hatred, they always seem to be having trouble tackling the matter of not falling in love... In the end it becomes rather clear in the EU that later Jedi consider the "no love" thing a rather dysfunctional rule. Even the movies hint at this as it's the "no love" nonsense that really drives Anakin toward the dark side and it's Luke's love for his father (that the older Jedi consider a weakness) that saved him. It's little surprise then that when Luke goes on to found his own order the no love rule is more or less totally abandoned with large numbers of Jedi marrying and producing children whom they clearly deeply care for without anyone saying this is bad.
In the end though, the rules seem to have been well justified. Anakin turned precisely because the Jedi ignored the rules and took someone with attachments that would later interfere with his mission. The post-ROTJ Jedi have been mired in familial conflict, with them not being as effective at sorting out problems. Mara literally refused to go out and fight a war because she had a son, Jaina nearly fell to the dark side because she had a lost someone she cared about, Luke and the entire Order were reluctant to deal with Jacen's actions in Lot F because he was family Luke himself nearly falling and being removed from the equation because of his love for Mara. The Jedi don't have a good track record without such rules.
The eponymous character of Robocop follows a number of Prime Directives. While 'Serve the Public Trust', 'Protect the Innocent' and 'Uphold the Law' follow the code of conduct aspect of the trope, additional Sub-Directives have on occasion been programmed into Robocop as restraining bolts that keep him from doing his job effectively.
In the Toy Storyuniverse, toys seem to have a Obstructive Code of Conduct. Toys must not allow themselves to be seen by humans while animate. This is never said explicitly, but judging from the fact that toys will either hide or "play dead" whenever a human comes by, it's probably safe to assume this.
Woody makes a vague mention of this in the first movie, when he and the reassembled toys confront Sid.
Woody: We're going to have to break a few rules.
Word Of God is that involuntary instinct also plays a role (which explains why it's never made explicit).
In the Superman movie the reason given (though in a piecemeal and blink-or-you'll-miss-it way) for Superman's non-interference with the world on a large scale is that due to early interplanetary warfare an intergalactic law was set in place for people from one planet never to interfere with the course of history of another planet. To break it might cause more harm than good: it could start an intergalactic war. No prize for guessing whether he breaks it at the end anyway.
Played with in the Pirates of the Caribbean series, with the Pirate's Code, primarily the invocation of parlay. In the first movie Barbosa alternately follows it like ironclad law, skirts around it or ignores it entirely ("It's more of a set of suggestions"). It becomes something of a running joke through the first and second movies, until Captain Teague is called out in the third movie, along with a massive tome concept outlining the entire Code. It turns out the whole "set of suggestions" only applies on the seas where there's no one to enforce it, which one pirate speaking for his Pirate Lord learns Teague does very efficiently.
In the Harry Potter books, the wizarding world has hidden from the Muggle (non-magic) world since 1689, and the International Statute of Secrecy is one of their most important laws. The reasons given are "everyone'd want magical solutions to their problems" and "they'd persecute us"note Word Of God says it's actually because the wizards are afraid of muggles. There are strict rules about performing magic in front of muggles and, if you're underage, anywhere outside of school. In essence, they amount to it having to be a life-or-death situation.
Sector General: The Monitor Corps have a Alien Non-Interference Clause similar to that of Star Trek, meaning no contact before the discovery of FTL, but seemed to be much more reasonable with it, as they violated it four times during the series. Once was because a pandemic (although, through no fault of the person in charge, the cure resulted in a genocide), once was because of an environmental disaster, once was because the civilization was killing off another intelligent being on the planet (as well as itself), and once because the species involved were physically incapable of spaceflight, due to an inherent psychological problem.
The Andalites of Animorphs have the Law of Seerow's Kindness forbidding them from sharing technology or other sensitive knowledge with aliens. It's named for Prince Seerow, who provided advanced technology to the then-primitive Yeerks. Prince Elfangor broke this law by giving morphing powers to the title characters.
The Ellimist claims that, as a rule, he never interferes with mortal races, but in actual practice he finds many excuses to interfere.
The Ellimist's rules are generally based on the game he plays with Crayak. Because both of them are so powerful that they could wreck the entire galaxy if they felt like it (their battles were at the stage where they were hurling planets and suns and even solar systems at each other, destroying what might have been an entire arm of the galaxy' and this was before they got their God-power upgrades), they have a rule that each time one interferes directly, the other is allowed a single action to balance it out. As a result, they fight their wars through proxies for the vast majority of the time.
At the end of one of the Vampire Chronicles novels, the surviving oldest vampires make a pact to stop making any more vampires, even though their version of Conservation of Ninjutsu states that the more vampires are out there the less they need to feed. Lestat, the Magnificent Bastard that he is, goes ahead and forcibly turns David Talbot the very next book.
In the Heralds of Valdemar series, the Companions are spirit advisors in corporeal form for the eponymous Heralds, taking the shape of cool horses. Most of the time, they're under strict divine orders not to interfere with the course of events, supplying advice and intervention only when asked. This is strongly justified, as the gods want the Heralds to solve problems on their own rather than rely on the Companions as a personal source of Deus Ex Machinas, and because the Companions themselves are fallible and risk falling into the Omniscient Morality License trap. Sometimes, however, the Companions are seen to subtly (or not so subtly) influence things behind the scenes, and they get called out on this rather severely by Elspeth in Mage Winds.
In Twilight and other related books, the Volturi enforce laws that all other vampires must follow: any humans who learn of vampires must be turned into vampires or killed, do not turn babies or toddlers into vampires, do not make alliances with werewolves, do not hunt in Volterra, do not lie to or defy The Volturi. The punishment is death, but The Volturi often bends the rules and invites vampires with special talents to join them.
The Wheel of Time's Aes Sedai are magically bound by three prohibitions: they can't lie, they can't make weapons, and they can't use magic as a weapon except against Shadowspawn or as a last resort in self-defense. They are so well known for circumventing the prohibition against lying that they're invariably met with suspicion. The last prohibition, however, causes the Aes Sedai no end of trouble as they encounter groups bent on their annihilation that are not, technically, allied with the Shadow. They generally circumvent the problem by deliberately placing themselves in mortal danger until they feel that they have no alternatives to letting loose.
The War Gods series has Wencit of Rūm, a wizard who's sworn to enforce the Strictures of Ottovar, that strictly forbid using magic against non-wizards except in direct and non-lethal self defense, and contain a strict dueling code for wizard to wizard action. Both instances of him joining combat include him enlisting the aid of non-wizards to work around the rules. For a dark wizard, fulfilling the requirements for Wencit to attack them means instant death.
The Valar and Maiar are both limited in the amount of intervention they can take in MiddleEarth. Considering that the times the Valar have intervened, entire continents have been sunk, they may have a point.
"As the right of each sentient species to live in accordance with its normal cultural evolution is considered sacred, no Star Fleet personnel may interfere with the healthy development of alien life and culture. Such interference includes the introduction of superior knowledge, strength, or technology to a world whose society is incapable of handling such advantages wisely. Star Fleet personnel may not violate this Prime Directive, even to save their lives and/or their ship unless they are acting to right an earlier violation or an accidental contamination of said culture. This directive takes precedence over any and all other considerations, and carries with it the highest moral obligation."
One of Gene Roddenberry's favorite Aesops involved the distinctions between the spirit of the law and the letter of the law. In particular, the "healthy development" phrase proved, on several occasions, to be a loophole big enough to fly the Enterprise through, while on other occasions, serious debate has been put up on the question of whether getting annihilated by the disaster-of-the-week is part of said "healthy development".
Currently, there are only two directives that are known to supersede the Prime Directive: the Omega Directive (which aims at protecting the galaxy from a phenomenon that, if left unchecked, would render interstellar society impossible) and the Temporal Prime Directive (don't mess with the timeline).
In Babylon 5, the Psi Corps rules basically exist only so that telepaths can break them to show that it's really serious this time.
At times, the Time Lords from Doctor Who have tried to maintain this, even putting the Doctor on trial for its violation at one point; a few other episodes have had him ask the people he's saved (if any survive) to not mention him. In other cases, the Time Lords have redirected his TARDIS to places they wanted fixed by him without admitting their involvement.
In Frontios, the Doctor does his very best to keep out of it — until he sees there are injured. Then, at the end, he asks them not to spread the news.
Highlander employed it constantly as well (do not fight on holy ground, do not fight in front of other people, etc).
Highlander Endgame had the villain violate the holy ground rule. This caused Fan Backlash so bad the bit mentioning holy ground was cut from the DVD release, leading to a plot hole instead. Fans took it badly than many a worst villains abided by that rule, and several material like Highlander: The Series inferred near-apocalyptic consequences to violating it (It was said the last time someone did it, Vesuvius happened to Pompeii". Yet when the villain of Endgame did it, nothing happened.
Also, in Sliders, the Professor originally insisted on employing a similar Prime Directive to that of Star Trek — namely, not getting involved in the world's culture and politics. Obviously, they always violated this directive, even when it was unnecessary for their survival (for example, the Professor winning the mayoral election in a female dominated society).
The Nox are perhaps even more into this idea. Both they and the Nox get incredibly annoying about it ("You are very young," anyone?) The Asgard initially take this path as well, until they're just about to go extinct, at which point they dump the sum total of their knowledge on us, superweapons and all.
Both times Daniel ends up ascended, he finds himself frustrated and angry with the fact that he can't use his new knowledge and abilities to help anyone, since he has a "The Messiah" personality but the governing body of the Ascended Plane enforces a strict code of non-interference. Ultimately he decides to do what he can to help and accepts the consequence of getting sent back to mortality.
Anubis is in somewhat the same situation, except in his case he wants to destroy the galaxy and he only manages to use his semi-ascended knowledge to further his goals for two reasons: first, he's really great at subverting the rules and finding loopholes; and second, he's being kept around semi-ascended instead of sent back entirely as a way to punish the person who helped him to ascend in the first place.
The Tollan also qualify. Despite being a younger civilization, they have advanced centuries beyond Earthlings (possibly, due to the lack of anti-science movements in their culture). They refuse to give any of their technology to less advanced races. This is justified in their case, as their previous experience with giving technology to a less advanced civilization ended in an Earth-Shattering Kaboom. Later, however, after the untimely death (read: murder) of one of their leaders, the Tollan offer to trade their powerful ion cannons to Earth in exchange for Unobtainium. This turns out to be a ruse, and the Tollan are wiped out as a result. It should be noted, though, that it would still have taken Earth scientists decades, if not centuries, to reverse-engineer and understand the workings of Tollan technology, which would explain why one of the Tollan broke their rule and gave a device to Carter.
P Lus the Goa'uld had just developed motherships with shields that could resist the ion cannons, making them just an ordinary weapon.
The aliens of 3rd Rock From The Sun also had a Prime Directive-like policy about interfering with the Earth. Explained thus:
Dick: We can make little differences, we just can't make global differences. Harry: Can we blow up the Earth? Dick: You see, that's a global difference. Harry: It's so hard to keep track of all this.
Thunderbirds has their policy of maintaining strict secrecy about their organization and equipment when they could indirectly save many more lives licensing their vehicles to various emergency response services and militaries as standard issue equipment.
Vampires in the White Wolf's Tabletop RPG Vampire The Requiem have three Traditions that they must follow or face the wrath of the elders:
1- Masquerade: Vampires must not reveal their existence to mortals.
2- Diablerie: Vampires must not devour the souls of other Vampires. Doing so gives them power, but drives them insane.
3- Progeny: Vampires shall not create more of their own kind. When they do, the Childe's actions are the Sire's burden.
In short, rule one and three are barely considered loose guidelines. Rule 2 is obviously considered a bad thing, mostly because Vampires expect it to be done to them next. They're usually right.
The Camarilla from Vampire The Masquerade had six Traditions which also needed to be followed to avoid the wrath of the elders:
1- Masquerade: Pretty much the same deal as in Requiem.
2- Domain: When a vampire has a domain, all others must owe that vampire respect when in it, and none may challenge their word. This is primarily used for princes.
3- Progeny: Vampires may not create others of their kind without their elder's (read: the prince's) permission, or else both they and their progeny will be slain.
4- Accounting: If you do create another vampire, you're responsible for them until such time as you release them, including any trouble they might get into.
5- Hospitality: When traveling to a foreign city, you must present yourself to the prince of that city and gain his acceptance.
6- Destruction: Vampires are forbidden to kill each other. The right of destruction belongs only to your elder (read: the prince), and only the eldest among vampires of a given city can call a Blood Hunt.
As you might expect, many of these rules get bent or outright broken with some degree of regularity. The Camarilla is especially hard on those who break the Masquerade.
Dungeons & Dragons: The Paladin in many incarnations of the game has one of these by design. For starters, they must always maintain an alignment of Lawful Good, and if they ever stray from it, they must atone and perform penance as prescribed by a high-level priest before they can call upon their powers again — but if the breach was intentional, their paladinhood is lost forever, and they must ever after be a fighter. In particular, any intentionally-committed evil act automatically forfeits your paladinhood. This often cuts off a wide range of traditional player character activities and can get the character into trouble when the choice is: damned if you do, dead if you don't. This is especially true if you have a Killer Game Master, who will often make paladins "fall" for such small things that it effectively becomes impossible to actually stay one for very long.
Paladins could become anti-paladins, depending on alternate rulesets.
The 1st and 2nd Edition paladin had several additional restrictions as well, such as not being able to own more than a few magic items. The 1E ranger was likewise limited in how many possessions could be owned, and had to be Good-aligned.
Several other classes have alignment restrictions as well, although they aren't as stringent in that it takes a full-on alignment change to break this Code, not just a single act. Also, they don't lose their existing powers, they just can't advance any further in the class they've broken the Code of.
Monks can't advance any further in that class if they take a level in a non-monk class.
Removed in 4th Edition. Clerics and paladins can change their alignment and break codes later.
In Unknown Armies, the Taboo of any magick-user is basically this. There are some behaviors that you cannot engage in, ever, or you weaken your power in some way. For example, the Taboo of a Healer Avatar is denying a cry for help. If they do so, they lose points in their Avatar skill.
The Nobilis are bound by one of these, and risk being hauled in front of the Locust Court if they break it. There are five rules, ranging from the relatively mild (don't protect those from the justice of the Code), to the annoying and inconvenient ("treat no beast as your lord", which technically prohibits things like doing your mortal job), to the actively harmful (don't harm those who have done no harm, which sounds nice but also means you can't sort out Excrucians until they're engaged in an active flower rite), to the borderline impossible (thou shalt not love). Admittedly, that last one exists mainly to ensure that everyone is guilty of something.
There is one in Kingdom Hearts; do not meddle in the affairs of other worlds except to protect them from The Heartless, but it has been so blatantly violated through BOTH games that no one really cares anymore.
The gods of Mortal Kombat abide by a highly restrictive set of rules set forth by the Elder Gods. This greatly limits the options available to the heroes, as the Elder Gods are often willing to stand idly by in the face of great evil.
The "provisos and quid pro quos" of genies in Disney's Aladdin:
1. A genie can't make anyone simply fall in love (though they're allowed to play cupid mundanely).
2. A genie can't kill anyone (implicitly, even indirectly or nonmagically — however, as is repeatedly warned, "you'd be surprised what you can live through ...")
3. A genie can't raise anyone from the dead.
There is an additional rule, saying that one cannot wish for extra wishes beyond the initial three.
These were initially presented in the original movie as limitations on granted wishes, but became implicitly upgraded to general behavioral rules in the direct-to-video sequel (that also functioned as the pilot of the TV series).
The second rule can be bent greatly. In the climactic scene of Return of Jafar, Jafar opened up a pit of lava beneath Aladdin's feet, with only a few rapidly sinking towers of stone keeping him from a molten death.
Da Rulez from Fairly Oddparents restricted the unlimited magic of fairies, disallowing them from making people fall in love, or die, or to maim, crush, cut, etc. (directly, anyhow, it was theorized on the show one could turn someone into an ice sculpture then "poof" them into the sun), or break the law, such as asking for money (as they can't make more, which is counterfeiting, or get some from others, which would be stealing). Some of these rules seem like simple incapabilities on the fairies' part; others are breakable, but have huge consequences, such as revealing the fairy godparents to anyone who isn't already aware of them. They are frequently broken as comedy requires.
One rule specifically applies to Timmy Turner, forbidding him from time travelling to the month of March, 1972. He's still allowed to visit other months of that year on the proviso he doesn't interfere with the election of President Mc Govern.
Because of the mess caused when Timmy wished it'd be Christmas Every Day, a new rule has been passed against wishing for that.
Making secret wishes became the most egregious violation of Da Rules ever since Joshua Applebee used one to wish for a fairy-eating giant cockatrice.
Genies have no rule other than having to grant their master's wishes in any way they can interpret the wish's wording. When asked, genies usually claim their masters can't use any of their wishes to wish for more wishes. The only exception was when Crocker became Norm's master. Norm and Crocker shared a common interest (Timmy's destruction)
Spoofed in Sev Trek: Puss in Boots when Commander Piker (Will Riker) is infected by an enormous zit that turns out to be an evolving sentient lifeform.
Pinchhard: Number One, I can't order you to host the pimple; I can only remind you of the PC Directive, and your responsibilities as a Sevfleet officer!
Piker: I see — it's my choice only if I choose what you want!
In Avatar The Last Airbender, at the beginning of the second season, Aang wants to skip his Prime Directive of learning the four bending arts and go straight to the Fire Lord and take him out with the all powerful Avatar State, however he soon learns without control of this state he could easily hurt those around him and decides to take the traditional way by learning the bending arts first.
Another unwritten rule seems to be that the Avatar should learn the elements 'in order', starting with their natural element, air, water, earth and fire. Aang tries to learn Firebending second, but that doesn't really work out, he also learns several elements at the same time, otherwise the rule is followed by Aang.
In El Goonish Shive, Immortals are not allowed to do more than empower and guide humans when they deal with matters on the physical plane of the universe or they incur the wrath of other Immortals.
One episode of Mr Deity has the titular god refusing to help out on Earth because it would violate the Prime Directive. Larry spends most of the episode trying to convince Mr. Deity that he's getting his own rules confused with Star Trek.
The Caretaker Gods of Orion's Arm have an active version of this. They prevent terragen lifeforms (anything with an ancestry going back to Earth) from contacting various planets, moon and solar systems that they have declared to be protected. This includes Old Earthitself.
Mining Magnate Gina Rhinehart's attempt to buy out Fairfax Newspapers in Australia in order to promote her views (something which left-wingers feel Rupert Murdoch's papers do for free). She is now the largest shareholder, but is unable to take a seat on the board unless she signs a clause guaranteeing the papers' editorial independence, which she refuses to do.