Answer by taking a quote from the following article:

Jens Ingemar Johansson (Swedish: ['ING:emar 2ju:hans,son]; 22 September 1932 - 30 January 2009) was a Swedish professional boxer who competed from 1952 to 1963. He held the world heavyweight title from 1959 to 1960, and was the fifth heavyweight champion born outside the United States. Johansson won the title by defeating Floyd Patterson via third-round stoppage, after flooring him seven times in that round. For this achievement, Johansson was awarded the Hickok Belt as top professional athlete of the year--the only non-American to do so in the belt's entire 27-year existence--and was named the Associated Press Male Athlete of the Year and Sports Illustrated Sportsman of the Year.

Johansson earned his shot at the world heavyweight crown when he knocked out top ranked contender Eddie Machen in the first round of their elimination match on 14 September 1958. In front of 53,615 fans in Ullevi football stadium, Johansson downed Machen three times, finally finishing him with a barrage of punches at 2:16 of the first round. Johansson then signed to fight champion Floyd Patterson.  Johansson was a colourful figure in New York City as he trained for the fight. Eschewing the monastic training regimen favored by Patterson and other fighters, Johansson trained at the Catskill resort of Grossingers. He did not seem to train particularly hard, and was often seen at night spots with his attractive girlfriend, Elaine Sloane, whom he asked out while she was working for Sports Illustrated.  He entered the ring in Yankee Stadium on 26 June 1959, as a 5-1 underdog. Johansson spent the first two rounds of the encounter retreating and flicking a light left jab at the champion. In the third round, Johansson threw a wide left hook that Patterson blocked with his right hand. When he moved his right hand away from its protective peek-a-boo position before his chin, Johansson drilled him with a short powerful right hand. Patterson went down, arose on unsteady legs and was out on his feet. Johansson followed up his advantage and sent Patterson down six more times in the round before the bout was stopped by referee Ruby Goldstein. Johansson celebrated with his girlfriend and future wife Birgit Lundgren and the next day a headline in a New York newspaper expressed the city's amazement. It read: "Ingo - It's Bingo."  When Johansson returned to Sweden, he flew in on a helicopter, landing in the main football stadium in Gothenburg, his home town, and was cheered by 20,000 people. He appeared on the cover of Sports Illustrated, as well as the cover of Life Magazine on 20 July 1959, alongside Birgit.  Johansson was a flamboyant champion - a precursor to the "Swinging Sixties". One publication dubbed Johansson "boxing's Cary Grant" and in 1960 he appeared in the movie All the Young Men as a marine, alongside stars Alan Ladd and Sidney Poitier. Wherever he went, in the U.S. or in Sweden, he had a beautiful woman on his arm, with paparazzi snapping pictures.  To train for the third fight with Patterson, Ingemar sparred with a young Muhammad Ali, (known then as Cassius Clay) in Miami Beach. After Cassius had "boxed his way around the ring, as if it was he, using 'Ingo' as a sparring partner", somebody offered $100,000 to Ingemar to fight in a televised event with Ali, but Ingemar declined saying that the fight would not draw three ticket holders and that Ali did not have the ability to step in the ring with him at that time.

when did he become heavyweight champion?
He entered the ring in Yankee Stadium on 26 June 1959, as a 5-1 underdog.