Yahoo Inc. is giving its popular email service a long-promised facelift in an attempt to make it more appealing to people who are increasingly using Facebook, Twitter, Google and other online alternatives to communicate.

The changes announced on Tuesday build upon a redesigned email format that Yahoo began testing seven months ago. The estimated 277 million users of Yahoo’s free email service will be switched to the new version during the next few weeks.

The overhaul will enable updates to Facebook and Twitter accounts to be posted from within Yahoo’s email boxes. The revamped service is supposed to be two times faster and capable of sending attachments of up to 100 megabytes. Other tools include better junk-mail controls and the ability to chat with friends and family logged into Facebook.

Yahoo is counting on the changes to help attract and retain email users at a time when more people are flocking to the rival Gmail service run by Internet search leader Google Inc.

Although Yahoo’s service remains larger than Gmail, it has been losing ground in the past year. Through April, Yahoo boasted 277 million email users worldwide, a drop of about 3 million, or 1 percent, from the same time last year, according to the research firm comScore Inc. Meanwhile, Gmail had grown to 220 million wordwide users, up 43 million, or 24 percent during the past year.

Most of Gmail’s gains appear to be coming at the expense of Microsoft Corp.’s Hotmail service, which remained the global leader with 327 million users, according to comScore. But that figure was down 27 million, or 8 percent, from last year.

Cultivating loyal email users is important because they tend to be frequent visitors and they often remain logged in when using other online services run by the email providers. The return trips and logged-in activity creates more opportunities to show Internet ads, the main way that both Yahoo and Google make money.

Yahoo, though, hasn’t been luring as many advertisers as Google for years, a problem that has weighed on Yahoo’s stock.

The email upgrade is expected to be among the signs of progress that Yahoo CEO Carol Bartz emphasizes Wednesday when she and other top company executives are scheduled to update analysts on their turnaround plan.