SAN FRANCISCO — The World Cup had a second winner: Twitter.

The social networking company reported strong growth in the second quarter, driven in part by heavy use of the service by soccer fans around the world during the monthlong tournament, which spanned June and July.

Twitter’s results far exceeded Wall Street’s expectations, and the company’s shares rose about 29 percent in after-hours trading.

“During the World Cup, we delivered the kind of events experience that I’ve wanted to see from us for some time,” Dick Costolo, Twitter’s chief executive, said in a conference call with analysts. The service was tailored to each game and each country’s fans, giving a more personalized experience than new users have typically encountered in the past.

Revenue soared 124 percent during the quarter and the average number of people using the microblogging service in its June quarter was up 6 percent from its March quarter.