Talk-show host and media magnate Oprah Winfrey is buying a 10 percent stake in Weight Watchers International Inc in a vote of confidence for a company that is helping her and millions of others lose weight.

Shares of Weight Watchers nearly doubled in pre-market trading.

Winfrey, who for years has struggled publicly with her weight, will also join the board of Weight Watchers as the company reinvents itself to promote healthy lifestyles as well as its weight-loss programs.

Related: Exercise pill could put an end to working out

"I believe in the program so much I decided to invest in the company and partner in its evolution," Winfrey said in a statement.

Winfrey has been vocal about her tryst with weight loss and a thyroid problem which once led her to weigh 200 pounds in 2008. 

"Weight Watchers has given me the tools to begin to make the lasting shift that I and so many of us who are struggling with weight have longed for," Winfrey said.

Winfrey will help broaden Weight Watchers' reach and appeal and the company plans to feature her in its marketing, Chief Executive Jim Chambers said in an email to Reuters.

The availability of free weight management mobile apps and the popularity of fitness bands and devices, such as those made by Fitbit Inc, have eaten into the user base of Weight Watchers.

Singers Jessica Simpson and Jennifer Hudson are other celebrities who have endorsed Weight Watchers' programs.

Winfrey will buy nearly 6.4 million shares at Friday's closing price of $6.79 per share for $43.2 million. She will also have options to acquire an additional 5 percent stake.

If Winfrey buys 15 percent of Weight Watchers, she will become the second-largest shareholder, after investment firm Invus Public Equities Advisors LLC, which owned a 51.5 percent stake as of June 30.

She will also advise the company on program development and future products.

Up to Friday's close, Weight Watchers shares had tumbled 72.6 percent this year.