Panasonic has sold its entire stake in longstanding battery partner Tesla for about ¥400bn ($3.6bn) as it seeks to raise cash to finance its biggest-ever overseas acquisition.

The Japanese conglomerate, which has a $5bn joint battery manufacturing venture with Tesla in Nevada, said the sale would not affect its partnership with the US electric vehicle maker.

But the move comes after Panasonic made it clear that it wanted to reduce its heavy reliance on Tesla and supply batteries to other carmakers as the industry shifts to electric vehicles to reduce its carbon footprint.

The Japanese group acquired 1.4m Tesla shares at $21.15 each in 2010 for about $30m. As of March last year, it held shares worth ¥80.9bn, but that stake was reduced to zero by the end of this past March, according to a filing on Friday. During those 12 months, Tesla’s stock rose more than six-fold. It closed at $679.82 on Thursday.

“The purpose is to review strategically-held shares following the corporate governance guidelines,” the company said in an emailed statement. “It does not affect the partnership with Tesla and we continue to maintain good relationships.”

Since the 2010 investment, Elon Musk has transformed Tesla from a cash-strapped, lossmaking start-up to the world’s most valuable carmaker worth $655bn — almost 23 times bigger than Panasonic’s market value, even after shares closed 4.9 per cent higher on Friday.

While Panasonic used to be Tesla’s sole battery supplier, the US group has begun developing its own batteries and adding to its purchasing partners with South Korea’s LG Chem and China’s CATL to support growing sales of its vehicles.

For Panasonic, its $2bn-plus investment in the joint battery manufacturing venture has finally started to pay off, as the Japanese group eked out its first annual profit from Tesla’s battery business for the fiscal year that ended in March.

But the Japanese conglomerate has been expanding investment in other areas to strengthen its position in software. In April, it announced a $7.1bn deal to buy US supply chain specialist Blue Yonder.

In an interview in March, Panasonic chair Kazuhiro Tsuga told the Financial Times that the group’s partnership with Tesla was entering “a different phase”. “At some point, we need to graduate from our one-legged approach of relying solely on Tesla,” Tsuga said. “We need to keep an eye on supplying manufacturers other than Tesla.”