[[caption-width-right:256: Assuming ViewersAreMorons, 1934–1968]]

''The Hays Code'' (the informal name for The Motion Picture Production Code), adopted in 1930 but not seriously enforced until 1934, was a set of rules governing American filmmaking that shaped--and in many ways stifled--American cinema for over three decades. It also happened to completely overlap UsefulNotes/TheGoldenAgeOfHollywood.

UsefulNotes/ThePreCodeEra of Hollywood cinema stretched from around 1928 to 1933, and the contrast between films made before and after the Hays Code was enacted shows the impact censorship had on American cinema. Films like Creator/HowardHawks' ''{{Film/Scarface 1932}}'' were far more brazen and upfront about DamnItFeelsGoodToBeAGangster, lacking the DoNotDoThisCoolThing tacked-on correctives seen in films like ''Film/AngelsWithDirtyFaces'' (though even during this era, with Hawks' film, the studio added scenes and changed the title to ''Scarface: The Shame of the Nation'' to appease local censorship boards). The landscape was also less politically correct, as actors and actresses played all kinds of roles. Lots of pre-Code films have a surprisingly feminist slant; working women are even regarded with sympathy and affection. William A. Wellman's ''Heroes for Sale'' (1933) shows a ShellShockedVeteran returning from World War I falling into morphine addiction. Directors such as Josef von Sternberg worked with Creator/MarleneDietrich to create provocative explorations of sexuality and power. 1930's ''Morocco'' even featured the first lesbian kiss in sound cinema.

During the later years of UsefulNotes/TheSilentAgeOfHollywood and the UsefulNotes/RiseOfTheTalkies, Hollywood became inundated with public complaints about the perceived lewd content of films. Scandals centered around big stars (most infamously Creator/FattyArbuckle) and the ensuing media frenzy made vocal sections of the public call for the government to rein in Hollywood. As luck would have it, the U.S. Supreme Court had ruled in 1915 that films did not qualify for First Amendment protection[[note]]The ruling in the 1915 case, ''Mutual Film Corporation v. Industrial Commission of Ohio'', said essentially that because film was a purely commercial endeavor, it therefore had no artistic merit, and thus could not count as free speech. [[DoubleStandard Live theatre operated under the same auspices, but had 1st Amendment protection--a fact conveniently ignored by the Court.]][[/note]]. Congress began to consider creating a national censorship board akin to the ones found in several states both before and after the ''Mutual'' Decision.

To stop the government from censoring or banning films, Hollywood decided to do the deed themselves with the Hays Code, a set of production directives voluntarily adopted by all the major studios that would ostensibly prove to Congress (and the public) that Hollywood had cleaned up its act. Will H. Hays, a former Postmaster General, did not create the Code, but he was the first head of the office of its enforcement, so his name became more-or-less permanently attached to it. Amongst filmmakers, Joseph Breen was the main man behind censorship, and the Hays Code was also known as the Breen Code. The Code placed a number of restrictions on all films produced, distributed, or exhibited by the members of the Motion Picture Producers and Distributors of America (MPPDA), the organization today known as the Motion Picture Association of America (MPAA).

The Hays Code restrictions were as follows:
* Crime and immorality could never be portrayed in a positive light. [[CantGetAwayWithNuthin If someone performed an immoral act, they had to be punished on screen]].
** This forced a change to the ending of ''Literature/TheBadSeed''. In the novel and stage play, Christine gives an overdose of sleeping pills to her dangerous sociopathic daughter Rhoda, and Christine shoots herself, but Rhoda survives, with the implication [[TheBadGuyWins she will kill again]] (especially now that her mother, the only person aware of her true nature, is gone). The film version has Christine survive her suicide attempt, while Rhoda dies in a contrived and implausible KarmicDeath (she goes to the lake to find the penmanship medal for which she killed a boy, and a tree is struck by lightning and falls on her).
** The Hays Office made the ending of ''Film/TheBigSleep'' more violent and decisive than the one originally planned.
** TheReveal in ''Literature/{{Rebecca}}'' suffered as a result of this rule. Originally, [[spoiler:the cruel and faithless Rebecca is murdered by her husband Maxim]], but in Creator/AlfredHitchcock's 1940 film version, [[spoiler:her death is accidental and Maxim covers it up because he feels nobody will believe his innocence.]]
** This rule also disallowed morally derelict characters being DrivenToSuicide, which changed the originally planned ending of ''Film/AngelFace'' and the circumstances of Billy's death in ''Theatre/{{Carousel}}''.
** ''Disney/TheAdventuresOfIchabodAndMrToad'' portrayed [[Literature/TheWindInTheWillows Toad]] as being framed for theft, whereas in the book (and all future adaptations), he actually ''does'' steal the motorcar.
* Films could only present "correct standards of life" (for the times) unless the plot called for something else.
** One strange repercussion of this rule: some directors avoided taking on films that centered on poverty, as it could have conflicted with the Code.
* The law had to be respected and upheld.
** Cartoons could occasionally get away with breaking the law; such examples include the ''WesternAnimation/WoodyWoodpecker'' cartoon "The Screwdriver" and Creator/TexAvery's "Thugs With Dirty Mugs" (which was [[BannedInChina banned in Manitoba, Canada]] because the censors there thought the cartoon made light of violent crime).
* Nudity and overt portrayals and references to sexual behavior (even between consenting adults) could not be shown.
** Under this rule, the aftermath of sexual activity--pregnancy and the resulting childbirth--weren't allowed. In ''Film/GoneWithTheWind'', when Melanie Hamilton Wilkes was giving birth, she and Scarlett and Prissy were ''literally'' shown only as shadows on a wall because of this rule.
** The ban on anything that could be construed as sexual was what pretty much killed the ''WesternAnimation/BettyBoop'' cartoons. It also made Creator/MaeWest a star, as her films made good use of her innuendo-laden humor.
** ''WesternAnimation/RedHotRidingHood'' pushed the limits of what was allowed for fanservice on the silver screen. A lot of the [[SomethingElseAlsoRises sexually-charged wild takes]] were removed from prints for general audiences, but were reinstated in copies made for American soldiers fighting overseas during UsefulNotes/WorldWarII.
** The Creator/WalterLantz shorts "Abou Ben Boogie" and "The Greatest Man In Siam" also got away with a surprising amount of fanservice, although this eventually kept them banned from TV airings in later years.
** The word "virgin" was banned for this reason, and it was {{Bowdlerise}}d out of the film versions of ''Theatre/{{Carousel}}'' and ''The Rose Tattoo''. It was mostly because of the usage of that word that led to ''Theatre/TheMoonIsBlue'' being released without Hays Code approval.
** While depicting men and women in bed together wasn't strictly forbidden--it was in the "be careful" section, rather than the "don't" section--SleepingSingle became a universal trope thanks to this rule, and it remained such until the 1960s.
** It was necessary in all romantic scenes for a woman to have at least one foot on the floor, to prevent love scenes in bed. This led to FootPopping becoming popular.
** The Hays Office had many issues with ''{{Film/Casablanca}}'', most of them related to sexual content. In the unproduced play which the film was based on, the ending featured Lois ([[AdaptationNameChange renamed Ilsa in the film]]) sleeping with Rick for the [[MacGuffin letters of transit]]. The Hays Code put an end to that. Rick and Ilsa's affair in Paris was only allowed because she believed her husband was dead at the time. Still, the censors tried to quash any hint that they might have slept together while in Paris. The Hays Office also objected to Captain Renault's use of the ScarpiaUltimatum, only allowing it after it was toned down so that it's only implied.
* Religion could never be depicted in a mocking manner.
** In some cases, this had the effect of preventing religion being depicted ''at all'', for fear of being deemed mocking after the fact.
** This rule almost got the WesternAnimation/CensoredEleven short "Clean Pastures" banned in the time it was released, as it showed a burlesque of religion with black people depicted as angels going to Heaven (not to mention glorifying gambling and jazz in the same mention as Heaven, both of which were considered taboo back then).
** This rule also led to characters who had previously been depicted as [[SinisterMinister less than exemplary]] [[NunTooHoly members of the clergy]] getting new careers in secular fields. Three notable examples:
*** Frollo in the 1939 adaptation of ''Film/TheHunchbackOfNotreDame'', who became a judge (pre-dating the Disney version by several decades).
*** Mr. Collins in the 1940 ''Film/PrideAndPrejudice'', who became a librarian.
*** Cardinal Richelieu became Prime Minister Richelieu when played by Creator/VincentPrice in the 1948 adaptation of ''Film/TheThreeMusketeers''.
* Drug use, including alcohol consumption, could not be shown unless the plot called for it.
** Under the first version of the Code, drug use was allowed only if the story was a cautionary tale against drug abuse...or if the druggie got what they deserved for doing it in the first place (this was why ''Reefer Madness'' managed to be released, even if the message that drugs are bad was artificial and tacked-on). Illegal narcotics were strictly prohibited, no matter what the circumstances.
* All detailed (that is, [[DontTryThisAtHome imitable]]) depiction of crime had to be removed. This included lockpicking, safe-cracking, or the mixing of chemicals to make explosives.
* Films could not use {{revenge}} as a theme or premise in stories set during modern times, since it could be seen as glorifying violence (specifically murder).
** The Code made exceptions for historical settings--particularly where there was no law to punish the offender--so Westerns became the only movies allowed to have revenge as a theme or premise.
* Topics considered [[ValuesDissonance "perverse"]] could not be discussed or depicted in any way. Such topics included--but were not limited to--homosexuality, miscegenation (interracial relationships), bestiality, and venereal diseases.
** Studios used the explicitly racist ban on depicting miscegenation to justify the exclusion of non-white actors from employment: they reasoned that the Code would be breached if ''either actor or character'' was of a differing race. Anna May Wong, the leading Chinese-American actress of the time, was rejected as the female lead in ''Literature/TheGoodEarth'' because the male lead was white actor Paul Muni.
*** The Code actually advocated for the [[FairForItsDay inherent dignity of "foreign peoples"]] and insisted that their cultures not be undeservedly slurred. This didn't really help nonwhites who were American (especially not [[YellowPeril the Japanese]] during UsefulNotes/WorldWarII), but still.
** The bestiality ban was part of the reason for changes to ''WesternAnimation/RedHotRidingHood'''s original ending, which showed the Wolf forced into marriage by [[DirtyOldWoman the Grandma]], then years later, taking his half-human, half-lupine children to the nightclub to see Red perform. (The original ending, much like the "erection takes", exist on a DirectorsCut that was sent to overseas soldiers.)
* The sanctity of marriage had to be upheld.
** The Code is often credited as creating the ComedyOfRemarriage genre, as an act of infidelity wouldn't actually count as infidelity if the leads were (temporarily) divorced. But that genre [[OlderThanTheyThink already existed pre-Code]], so the credit is unwarranted.
* Blasphemy--including using the name of God as an expletive or exclamation--was not allowed. Using the word "God" was allowed, but only if used in a reverent tone or meaning.
* Profanity of any kind was prohibited.
** This rule and the blasphemy rule led to supposedly tough-and-gritty protagonists using mixtures of UnusualEuphemism and GoshDangItToHeck. Any word stronger than "damn" was completely disallowed, and any usage of profanity was likely to result in a hefty fine. (Rhett's famous line in ''Film/GoneWithTheWind'' was considered a big deal back then because of this rule.)
* The United States flag was to be treated with utmost respect.

These rules could be slightly skirted in film adaptations; for example, they managed to keep the famous line "Frankly my dear, I don't give a damn" in ''Film/GoneWithTheWind'' because the (mild) swearing was in the original novel. This was especially true for faithful adaptations of Creator/WilliamShakespeare's plays, which were likely considered too artistically significant to censor (''Theatre/{{Hamlet}}'', for instance, was filmed over a dozen times despite its main theme of revenge being something normally prohibited by the Office).

Since the Code did not apply to the stage, aspiring screenwriters could (and did) write plays about subjects too sexy or politically controversial for Hollywood. In New York (at least), stage censorship--though not unheard of--was far less of a threat than it had been in the 1920s (when Creator/MaeWest was jailed and the Wales Padlock Act was passed), and comedies quite freely made fun of the movie censors. [[http://kirk.is/2009/09/06/ One particular pin-up image]] was created specifically to see someone could break every single Code provision in a single still.

But even in the period of the worst censorship, several films and directors managed to [[GettingCrapPastTheRadar subvert it]]. The Creator/PrestonSturges comedy ''The Miracle of Morgan's Creek'' is a case in point; the film stars Betty Hutton, a good-time girl who gets impregnated by a GI Soldier [[RefugeInAudacity and gives birth to seven children]]. Creator/MartinScorsese, in his documentary on American movies of the same period, noted that some filmmakers used cinematic means and subtlety to suggest complex themes (and even subvert censorship mandates). This always involved the usage of subtext, MeaningfulBackgroundEvent, and StylisticSuck in the HappyEnding, which often made such endings very unconvincing to audiences and helped them sense [[DownerEnding the subtext]] lying just underneath. Scorsese cites films like ''Johnny Guitar'', which was a major TakeThat to the WitchHunt and the RedScare, and directors like Samuel Fuller and Douglas Sirk, who kept pushing the boundaries in terms of content. Fuller's ''The Steel Helmet'', made in 1950, was the first film that addressed the internment of Japanese-Americans in the Second World War, and he continued to make anti-racist films throughout that decade. His FilmNoir, ''Film/PickupOnSouthStreet'', provoked the ire of J. Edgar Hoover himself--but Fuller had the friendship of 20th Century Fox boss Darryl F. Zanuck, who backed him through all this. Douglas Sirk's ''Imitation of Life'', made in 1959, was the most successful Universal film until ''Airport'', and it portrayed the reality of race relations in pre-Civil Rights era with a stark eye. Elia Kazan, on the other hand, pushed the boundaries of sexuality with films like ''Baby Doll'', ''A Face in the Crowd'', and ''Film/SplendorInTheGrass''.

The mere fact that censorship had to be so rigorously enforced in the first place stands as a testament to how (and how often) directors and screenwriters tried to resist it. Even a classic like ''Film/RebelWithoutACause'' featured a barely-concealed homosexual as a sympathetic character (BuryYourGays is enforced, but it's clearly treated as a tragedy). Genre films tended to fall BeneathSuspicion, so directors of FilmNoir or TheWestern often had a freer hand than directors who made OscarBait films, the EpicMovie, or TheMusical. The BMovie side of things wasn't taken seriously by MoralGuardians; as a result, films like ''The Big Combo'', ''Detour'', ''Film/TouchOfEvil'', ''Murder by Contract,'' and ''The Crimson Kimono'' had more progressive and interesting content than the A-movies they played with on a double bill.

In 1948, the Supreme Court neutered the MPAA's ability to enforce the Code over all films shown in the US. The "Paramount Decision" (read more about that in UsefulNotes/FallOfTheStudioSystem), among many other things, ended the ability of the "Big 5" (MGM, Paramount, Fox, Warner Brothers, and RKO) studios to own the entirety of movie production, distribution, and exhibition. The major studios sold their theater chains, which meant they technically lost all say in what could be shown in those theaters. The new theater owners were no more eager to incur the wrath of the US government than the Big Five had been, though.

But the Supreme Court itself began to undercut the purpose of the Code (to prevent federal government censorship of the film industry) starting in 1952. The Italian film ''The Miracle'' by Roberto Rossellini, featured controversial use of religious imagery; its American release provoked a severe outcry. Film distributor Joseph Burstyn sued to have the short film's license reinstated in New York, and the Supreme Court did just that in what is now known as the "Miracle Decision", which helped give film First Amendment protections as an artistic medium. In the 1960s, a wave of European films (particularly British and Italian films like ''Film/{{Alfie}}'' and ''Film/BicycleThieves''), none of which were subject to the Code, tackled gritty topics that American studios couldn't touch because of the Code. American theaters could show these films without the MPAA's prior approval thanks to the Paramount Decision; when the MPAA tried to demand the censorship of those films, its efforts backfired and the Code ended up looking even more ridiculous. The Supreme Court essentially ended the MPAA's ability to even attempt censorship over any film with the 1965 ''Freedman v Maryland'' decision.

Prior to the Court loosening the reins, domestic filmmakers mounted serious challenges to the Code in the 1960s. ''Film/ThePawnbroker'' featured an artistically-essential topless scene and ''Theatre/WhosAfraidOfVirginiaWoolf'' featured equally-essential harsh language. Against the considerable critical acclaim of these films and overwhelming public sentiment, the Hays Code tried to bend--those films were considered "special exceptions"--but this opened the door for every daring filmmaker of the day to ask for similar consideration. This change of criteria also encouraged film company executives to stop cooperating with the Code: it was one thing for the Code's censors to have objections about specific content that fell into an agreed-upon criteria, but it was quite another for those censors to act as ''de facto'' film critics who could arbitrarily determine which films were of good enough quality to make them "exceptions".

In 1966, MGM released the film ''Film/{{Blowup}}''--which failed to gain Hays approval due its relatively explicit erotic content--in direct defiance of the Code. The MPAA and the Code could do nothing to stop MGM from distributing the critically-hailed film, which became a smash hit. Other studios soon followed MGM's lead when it became clear that the public's opinion of the Code had changed. Also in 1966, Jack Valenti was elected MPAA president with the specific promise to move from the Code to a ratings system, in theory based on the age-appropriate-ness of the film. The MPAA Film Rating System eventually replaced the Code, and though it has altered slightly over the years, it is still in use to this day. The fall of the Hays Code rid Hollywood of the last [[UsefulNotes/TheGoldenAgeOfHollywood Golden Age]] relic and marked the beginning of the "New Hollywood" era of the late '60s and [[TheSeventies the '70s]].

In the years since its creation, the MPAA rating system has itself been criticized by many people--notably film critic Creator/RogerEbert and the filmmakers of ''Film/ThisFilmIsNotYetRated''--for doling higher ratings based on depictions of sex, homosexuality, or other controversial topics (and obscenity, to a certain extent) than depictions of violence. Other complaints note the lack of transparency about exactly ''why'' certain films get the ratings they do (for example, several films listed with "nothing offensive" as the whole MPAA content description have received PG ratings).

Creator/StephenColbert's book ''Literature/IAmAmericaAndSoCanYou'' contains a parody "excerpt" from the Code, including rules such as "Characters may not walk and chew gum at the same time," "If a train is shown entering a tunnel, the tunnel shall not be portrayed as enjoying it," "Characters may not discuss the high suicide rate among dentists in a manner that implies they have it coming," and "For Christ's sake, somebody put a bra on Creator/JeanHarlow". The excerpt also [[NumberOfTheBeast deliberately omits rule #666]], and also #669 for good measure.

Another example of mocking the Hays Code goes all the way back to 1942. In "A Tale of Two Kitties", a classic WesternAnimation/LooneyTunes cartoon directed by Bob Clampett, the cats [[Creator/AbbottAndCostello Babitt and Catstello]] plot to devour the ever-prepared Tweety Bird. At one point, Catstello is on a ladder to Tweety's nest and struggling with his fear of heights, while from the ground, Babitt starts pushing his buttons by yelling, "Give me the Bird! Give me the Bird!"--to which Catstello turns to the audience to say, "If the Hays Office would only let me, I'd [[FlippingTheBird give 'im the boid, all right]]". The really fun thing here is that animated shorts like this showed many different examples of breaking the Code--excessive violence ([[BloodlessCarnage though completely bloodless, of course]]) and (what was then) harsh language--simply because they were animated in ways that took everything to a level of pure parody. Rules were subverted, but in as overt a way as possible. (A non-animation example of this sort of Hays Code subversion would be Film/TheThreeStooges shorts, which were able to be the first to satirize UsefulNotes/AdolfHitler in Hollywood.)

The full text of the code can be found [[http://www.artsreformation.com/a001/hays-code.html here]]. The Broadway musical ''A Day in Hollywood/A Night In The Ukraine'' takes the text of Production Code and [[http://www.youtube.com/watch?v=iQqtmIrfUT8 has the cast dance to it]].

Critic Michael Medved, who is one of the very few film critics who supports MoralGuardians in many cases and who is more recently a right-wing Talk Radio host, makes the argument in at least partial support of the Code: "While many of the specific rules in the old Production Code look thoroughly ludicrous by today’s standards, it is instructive to recall that Creator/AlfredHitchcock and Creator/HowardHawks, Creator/JohnFord and Creator/BillyWilder, Creator/GeorgeCukor and Creator/FrankCapra and Creator/OrsonWelles all somehow managed to create their masterpieces under its auspices." But other critics contend that films by these directors were made in spite of the Code, and ExecutiveMeddling is responsible for flaws in even the greatest films of this time. Even so, Medved also makes the point that after the demise of the Code, motion picture attendance ''fell''--from ~44 million per week in 1965 to ~19 million per week in 1969--and that attendance has never reached the levels of the post-TV, pre-ratings age since, in absolute numbers (since 2000, for example, attendance in the US & Canada has fluctuated between 25–28 million tickets sold per week). [[note]]The explosive growth in broadcast television, cable, and home video of all kinds since 1977 has helped keep attendance down. But broadcast television had been responsible for the previous disastrous drop, from ~90 million tickets sold per week to ~45 million between 1948–53, and attendance had leveled off for the previous decade. Neither cable nor home video would enter American homes until the late 70s. Historians who try to blame video for ''causing'' the drop off between 1966–69 have a difficult case to make.[[/note]]

Compare this with UsefulNotes/TheComicsCode, which enforced similar restrictions on the ComicBook medium.