Elon Musk's charm offensive in China appears to have paid off.

The billionaire chief executive officer of Tesla won a tax exemption for the electric-car maker, got to promote his ground-digging Boring Co. passion project and even drew praise on social media for his frugal food and accommodation choices - he was spotted eating dumplings and staying at the Holiday Inn.

Elon Musk won plenty of fans on his trip to China. Credit:AP

Musk began making headlines in China on Thursday, when he publicly sparred with Alibaba Chairman Jack Ma at the World Artificial Intelligence Conference in Shanghai, talking about various subjects ranging from the existence of aliens to the preservation of human consciousness and other visions of the future.

Musk also toured a factory Tesla is building in the country and reportedly met China's Transport Minister Li Xiaopeng on Friday. Later that day, China announced Tesla cars will be exempted from a 10 per cent purchase tax, something typically reserved for domestic makers of electric vehicles.