"Bart's Girlfriend" was written by Jonathan Collier and directed by Susie Dietter. David Mirkin, who was show runner at the time, originally had the idea of Bart having a girlfriend that was more evil than he was. Mirkin gave the idea to Collier to write it with the help of the show's executive producer James L. Brooks. Collier said later that he thought it was a case of Brooks coming up with good ideas and him "giggling obsequiously". The idea for the ending of the episode was to have none of the characters learn anything from the experience.