On February 15, 1960, "Danny Meets Andy Griffith" was telecast on The Danny Thomas Show. In the episode, Griffith played fictional Sheriff Andy Taylor of Mayberry, North Carolina, who arrests Thomas for running a stop sign. Future players in The Andy Griffith Show, Frances Bavier and Ron Howard, appeared in the episode as townspeople, Henrietta Perkins, and Sheriff Taylor's son, Opie. General Foods, sponsor of The Danny Thomas Show, had first access to the spinoff and committed to it immediately. On October 3, 1960 at 9:30 p.m., The Andy Griffith Show made its debut. Andy is teamed with an inept but well-meaning deputy, Barney Fife (Don Knotts), has a spinster aunt and housekeeper, Aunt Bee (Frances Bavier), and a young son, Opie (Ron Howard, billed as Ronny).
Producer Aaron Ruben recalled:
"He was being that marvelously funny character from No Time for Sergeants, Will Stockdale [a role Griffith played on stage and in film]...One day he said, 'My God, I just realized that I'm the straight man. I'm playing straight to all these kooks around me.' He didn't like himself [in first year reruns]...and in the next season he changed, becoming this Lincolnesque character."
As Griffith stopped portraying some of the sheriffs more unsophisticated character traits and mannerisms, it was impossible for him to create his own problems and troubles in the manner of other central sitcom characters such as Lucy in I Love Lucy or Archie Bunker in All in the Family, whose problems were the result of their temperaments, philosophies and attitudes. Consequently, the characters around Taylor were employed to create the problems and troubles, with rock-solid Taylor stepping in as problem solver, mediator, advisor, disciplinarian and counselor. Aunt Bee, for example, was given several wayward romances requiring Andy's intervention, Opie suffered childhood missteps that needed a father's counsel and discipline, and Barney engaged in ill-considered acts on the job that required Sheriff Taylor's professional oversight and reprimand. Andy Griffith has also said that he realized during the earlier episodes of the program that it was much funnier for him to play the straight man to Knotts' "Barney," rather than his being the originator of the comedic scenes between them.
Andy's friends and neighbors include barber Floyd Lawson (Howard McNear), service station attendants and cousins Gomer Pyle (Jim Nabors) and Goober Pyle (George Lindsey), and local drunkard Otis Campbell (Hal Smith). On the distaff side, townswoman Clara Edwards (Hope Summers), Barney's sweetheart Thelma Lou (Betty Lynn) and Andy's schoolteacher sweetheart Helen Crump (Aneta Corsaut) become semi-regulars. Elinor Donahue made twelve appearances as Andy's girlfriend in the first season. In the color seasons, County Clerk Howard Sprague (Jack Dodson) and handyman Emmett Clark (Paul Hartman) appeared regularly, while Barney's replacement deputy Warren Ferguson (Jack Burns) appeared in the sixth season. Unseen characters such as telephone operator Sarah, and Barney's love interest, local diner waitress Juanita Beasley, as mentioned in first season episode "Andy Forecloses", are often referenced. In the series' last few episodes, farmer Sam Jones (Ken Berry) debuts, and later becomes the star of the show's sequel series, Mayberry R.F.D.. Knotts left the show at the end of the fifth season to pursue a career in films but returned to make five guest appearances as Barney in seasons six through eight. His last appearance in the final season in a story about a summit meeting with Russian dignitaries "ranked eleventh among single comedy programs most watched in television between 1960 to , with an audience of thirty-three and a half million."
The show was filmed at Desilu Studios, with exteriors filmed at Forty Acres in Culver City, CA. Woodsy locales were filmed north of Beverly Hills at Franklin Canyon. The show's theme music, "The Fishin' Hole", was composed by Earle Hagen and Herbert Spencer, with lyrics written by Everett Sloane. Whistling in the opening sequence, as well as the closing credits sequence, was performed by Earle Hagen. One of the show's tunes, "The Mayberry March", was reworked a number of times in different tempi, styles and orchestrations as background music.
The show's sole sponsor was General Foods, with promotional consideration paid for (in the form of cars) by Ford Motor Company (mentioned in the credits).
At the end of the show's fourth season (May 1964), the backdoor pilot Gomer Pyle, U.S.M.C. aired, and, the following September, the spinoff series Gomer Pyle, U.S.M.C. debuted with Jim Nabors in his Gomer role and Frank Sutton as drill instructor Sergeant Vince Carter.
In the last episodes of The Andy Griffith Show, the character Sam Jones, played by Ken Berry, was introduced and a sequel series, Mayberry R.F.D., was fashioned around him for the fall of 1968 (in essence replacing Andy Griffith — the '68 season would be his last).
Several performers reprised their original roles in the sequel, with Bavier becoming Sam's housekeeper. To create a smooth transition from the original series to Mayberry, Andy and Helen were married in the first episode, remained for a few additional episodes, and then left the show, with a move to Raleigh being the explanation given the audience. After the sequel series' cancellation in 1971, George Lindsey played a Goober-like character over several years on the popular variety show Hee Haw.
In 1986, the reunion telemovie Return to Mayberry was broadcast with several cast members reprising their original roles. Absent, however, was Frances Bavier. She was living in Siler City, North Carolina in ill health, and declined to participate. In the telemovie, Aunt Bee is portrayed as deceased, with Andy visiting her grave.