LONDON —

The global pandemic is forcing a pullback by advertisers on Twitter, but it’s also led to an unprecedented surge of users.

Average daily user growth spiked 34% in the second quarter, the company said Thursday, the largest jump in users ever recorded by the company.

Shares of Twitter surged more than 6% before the opening bell.

But the company took a huge tax hit to earnings, posting a net loss of $1.2 billion, or $1.56 per share, in the April-June period, compared with profit of $1.1 billion, or $1.43 per share, a year earlier.

Revenue fell by about a fifth to $683 million, far short of the $702 million Wall Street had expected, according to a survey of analysts by FactSet.

Twitters advertising business was hit harder than its larger rivals Google and Facebook, and analysts were expecting these losses to continue in the second quarter. But Facebook is the primary subject of a boycott by hundreds of advertisers over its policies and actions on hate speech and misinformation. The effect of the boycott, which runs for at least the month of July so would not be included in the second quarter, is not clear for Twitter some advertisers are pausing ads on all social media, while some analysts believe others may redirect ad spending to Twitter from Facebook.

That has not stopped new users from flocking to the platform as they isolate.

Twitters strength as a news and entertainment source has helped buoy engagement during the pandemic as housebound consumers use the platform for real-time news and information, said eMarketer analyst Jasmine Enberg. But she does not expect this to continue as stay-at-home restrictions are beginning to lift and people are starting to return to more normal routines.