Sidney Poitier insisted that the movie be filmed in the north because an incident in which he and Harry Belafonte were almost killed by Ku Klux Klansman during a visit to Mississippi. Hence the selection of Sparta, Illinois for the location filming. Nevertheless, the filmmakers and actors did venture briefly into Tennessee for the outdoor scenes at the cotton plantation, because there was no similar cotton plantation in Illinois that could be used. Poitier slept with a gun under his pillow during production in Tennessee. Poitier did receive threats from local racist thugs so the shoot was cut short and production returned to Illinois.
This was the first major Hollywood film in color that was lit with proper consideration for an actor with dark skin. Haskell Wexler recognized that standard lighting used in filming produced too much glare on most black actors and others of dark complexion. Wexler toned down the lighting to feature Sidney Poitier with better results.
Rod Steiger was asked by director Norman Jewison to chew gum when playing the part. He resisted at first but then grew to love the idea, and eventually went through 263 packs of gum during the shooting of the film.
Set in a hot Mississippi summer but filmed during autumn in Illinois, many of the actors had to keep ice chips in their mouths (and spit them out before takes) to prevent their breath from appearing on camera during the night scenes.
According to Sidney Poitier, Tibbs' retaliation slap to Endicott was not in the original script nor in the novel on which the film is based. Poitier insisted that Tibbs slap Endicott back and wanted a guarantee that the scene would appear in all prints of the film. According to Stirling Silliphant, the slap was in the original script though not in the novel.
When Norman Jewison and his editor Hal Ashby attended a sneak preview for the film, they found that the young audience was laughing uproariously at the dialogue. Although Jewison was upset that his dramatic film was not being taken seriously, Ashby assured him that the audience was laughing in approval of the southern sheriff being put in his place by the confident and urbane Det. Virgil Tibbs. Jewison did not agree until the film got to the famous slapping scene; when the white audience was stunned at seeing an African American man physically fight back against a white man for the first time in a modern mainstream American film, Jewison was convinced the film was effective as drama.
Mississippi was eventually ruled out as a location due to the existing political conditions. Sparta, Illinois, was selected as the location, and the town's name in the story was changed to Sparta so that local signs would not need to be changed. The greenhouse was added to an existing home and filled with $15,000 worth of orchids.
Due to the assassination of civil rights activist Martin Luther King (April 4, 1968), the presentation of the Best Picture Oscar for this film was postponed for two days from Monday April 8th to Wednesday April 10, 1968. (see also - The Life of Emile Zola (1937) and Raging Bull (1980)).
The slapping scene between Det. Tibbs and Endicott was shot in just two takes, and the slaps the characters made to each other's faces were real, according to a detailed account Norman Jewison, provided in 2011. Jewison let Larry Gates rehearse by slapping him because Jewison wanted to be sure that Gates could slap hard enough.
Rod Steiger received directions to base his performance as Sheriff Bill Gillespie on The Dodge Sheriff, a popular cultural icon and corporate spokesperson for Dodge automobiles. The Dodge Sheriff was a stereotypical southern sheriff used in an array of advertisements in the 1960s. Steiger took the advice, although he greatly toned down the comedic aspects of the character.
Scott Wilson so impressed Sidney Poitier that he contacted director Richard Brooks and suggested Wilson for a leading role in In Cold Blood (1967). Poitier never mentioned this to Wilson at the time, who only found out about this recommendation after he had been cast.
Ironically, Warren Oates and Lee Grant were among Hollywood's group of actors who played racist roles, or were in racist films, but were themselves up front and vocal in support of the civil rights movement at the same time. Others include Shelley Winters, and William Shatner.
A sign at the Sparta depot refers to the "Rebel Road." This is a reference to the Gulf Coast Rebel, a named train that began in 1937 and ran between Mobile and Union, MS, and was later extended to St. Louis. However, this would be an out of date artifact in 1966 as the GM&O ceased operations South of St. Louis in 1960 (although the company headquarters were in Mobile until 1972.)
The distributors hesitated to release the movie in the South states because of the high risks related of racial elements it contained. But it eventually occurred that there was no demonstration against the film in those southern states.
EMD E7A #103, the locomotive featured at the beginning and end of the film, was originally purchased by the Alton RR and acquired by GM&O in 1947 when it bought out Alton. The producers rented the train and crew for the movie.