Jani began karting in 1998 and moved to Formula Renault 2000 Eurocup in 2001, also contesting Italian Formula Renault that year and in 2002. In 2003, he joined the Formula Renault V6 Eurocup with Jenzer Motorsport and finished second in the championship by four points. For 2004, switching to the French DAMS team in the same series, he set a target of winning the title but finished fourth.
In 2005, Jani entered the GP2 Series with Racing Engineering alongside Borja García. He won two feature races, at the Hungaroring and at Monza, and demonstrated an ability to defend position in clearly slower machinery, notably leading much of the Nürburgring race through tactical driving. The following year he made substitute appearances for Arden International at Silverstone and Magny-Cours, replacing the injured Nicolas Lapierre. Those appearances placed him in a historically unusual position: he is the only driver recorded as having competed in both a GP2 race and a Formula One test on the same day.
Jani was confirmed as a third driver for Scuderia Toro Rosso from December 2005 for the 2006 Formula One season, alongside race drivers Scott Speed and Vitantonio Liuzzi, before leaving the role to pursue Champ Car.
Jani raced for A1 Team Switzerland across the four seasons of A1 Grand Prix, representing his home nation in the series marketed as the World Cup of Motorsport. In the inaugural season he helped Switzerland to a runner-up position, winning the Dubai Autodrome sprint race in the 2005-06 United Arab Emirates round. He won again in Malaysia during the 2006-07 season.
In 2007-08, Jani drove all races for Switzerland, winning four times and accumulating 168 points to take the series championship. Switzerland finished runner-up again in 2008-09 with Jani again ever-present.
For 2007, Jani drove for PKV Racing in the Champ Car World Series, finishing ninth overall. The series was absorbed into the IRL before the 2008 season, ending his North American open-wheel involvement.
Jani affiliated with Rebellion Racing from 2010, partnering Nicolas Prost in LMP1 machinery at Le Mans Series events and the 24 Hours of Le Mans. He also raced for Matech in the FIA GT1 season in a Ford GT that year. Full-time WEC racing followed in 2012 with Rebellion, teaming with Prost and Nick Heidfeld.
Jani joined the Porsche works LMP1 programme for the 2014 season. He won his first LMP1 race at São Paulo in 2014 and finished third in the championship. In 2015 he won at Bahrain and accumulated five runner-up finishes, again third in the championship.
The 2016 season brought his most celebrated result. Jani kicked off with a win at Silverstone and a second place at Spa, then inherited victory at the 24 Hours of Le Mans when Kazuki Nakajima's Toyota, which had held the lead throughout the race, broke down with approximately one lap remaining. The result gave Porsche the victory and Jani his Le Mans win.
Jani made his Formula E debut in the 2017-18 season with Faraday Future Dragon Racing alongside Jérôme d'Ambrosio but left the team after two rounds following back-to-back eighteenth-place finishes in Hong Kong. He returned to the championship in 2019-20 as part of Porsche's inaugural Formula E line-up alongside André Lotterer, racing until the end of the 2019-20 season.
In June 2023, Audi announced that Jani had signed as a simulator driver to assist in developing their power unit ahead of their planned Formula One entry in 2026, a role confirmed to extend to test driving duties for 2026.
Jani's career traced an unusual path from the Formula Renault ladder through A1 Grand Prix — where he won a world championship in a nationalistic team-based series — before finding his most significant success in LMP1 endurance racing with Porsche. The 2016 Le Mans victory was the result of both pace across the race and an extraordinary final-lap fortune, arriving after years of consistent top-level endurance performance that had placed him at or near the podium in multiple WEC seasons.