The pledge was made in an open letter to their newborn daughter, Max, who was born about a week ago.

Mr. Zuckerberg and his wife, Dr. Priscilla Chan, said they were forming a new organization, the Chan Zuckerberg Initiative, to manage the money, through an unusual limited liability corporate structure. “Our initial areas of focus will be personalized learning, curing disease, connecting people and building strong communities,” they wrote.

Mr. Zuckerberg’s charitable plans are the latest indication of a growing interest in philanthropy among Silicon Valley’s young billionaires, who unlike previous generations of business tycoons, appear eager to spread their wealth while they are still young. Mr. Zuckerberg is 31, and Dr. Chan is 30.

How Would You Give Away Your Fortune?

If you were Mark Zuckerberg and Priscilla Chan, how would you give away $45 billion, and why?

Yet they are entering largely uncharted waters with a charity effort of such scale. They have not yet detailed how the money will be spent and the pace at which the money will be given out indicates they plan to take their time.

The couple have had mixed results in earlier charitable efforts.

In 2010, Mr. Zuckerberg and Dr. Chan gave $100 million to improve the public schools in Newark. The money expanded high-performing charter schools but encountered fierce resistance from many parents, community activists and unions. Mr. Zuckerberg has said he learned a lot from the experience.

Still, Larry Brilliant, who works on philanthropic issues with many Silicon Valley figures including Marc Benioff, the chief executive of Salesforce.com, and Jeff Skoll, the co-founder of eBay, said that both the scale and timing of Mr. Zuckerberg’s commitment, coming so early in his career, were rare.

“I hope this will be a model for Mark’s generation,” said Dr. Brilliant, a physician who also previously ran Google’s charitable arm,Google.org.

The Silicon Valley way of philanthropy also demands more control over where the money is spent, though it remains to be seen if this hands-on formula will be successful.

By using a limited liability company instead of a nonprofit corporation or foundation, the Zuckerberg family will be able to go beyond making philanthropic grants. They will invest in companies, lobby for legislation and seek to influence public policy debates, which nonprofits are restricted from doing under tax laws. A spokeswoman for the family said that any profits from the investments would be plowed back into the Chan Zuckerberg Initiative for future projects.

“We must build technology to make change. Many institutions invest money in these challenges, but most progress comes from productivity gains through innovation,” they wrote in the letter to their daughter. “We must participate in policy and advocacy to shape debates. Many institutions are unwilling to do this, but progress must be supported by movements to be sustainable.”

In a securities filing, Facebook said Mr. Zuckerberg planned “to sell or gift no more than $1 billion of Facebook stock each year for the next three years.” He intends to retain his majority voting position in the company’s stock for the foreseeable future.

This week, Mr. Zuckerberg was also one of the billionaires who signed on to the Breakthrough Energy Coalition, a group organized by the Microsoft co-founder Bill Gates to contribute toward a multibillion-dollar clean energy fund. The announcement coincided with a Paris summit meeting intended to forge a global accord to cut planet-warming emissions.

Mr. Zuckerberg has referred to Mr. Gates as one of his childhood heroes for his zeal in building Microsoft into a colossus in the technology industry. Mr. Gates is the wealthiest person in the world, with an estimated worth of $85.2 billion, according to the Bloomberg Billionaires Index. The index estimates that Mr. Zuckerberg’s total worth is $46.8 billion.

Mr. Zuckerberg has admired Mr. Gates’s philanthropic endeavors, too, becoming one of the first people to join the Giving Pledge, an initiative started by Mr. Gates and Warren E. Buffett to get wealthy individuals and their families to give away more than half of their wealth to charities during their lifetimes or after. Mr. Gates has pledged to give away at least 95 percent of his wealth.

“None of this would have happened without Bill Gates,” Dr. Brilliant said.

In a statement, Mr. Gates and his wife, Melinda, congratulated Mr. Zuckerberg and Dr. Chan.

“The example you’re setting today is an inspiration to us and the world,” they said. “We can be confident of this: Max and every child born today will grow up in a world that is better than the one we know now. As you say, ‘Seeds planted now will grow.’ Your work will bear fruit for many decades to come.”

Mr. Zuckerberg and Dr. Chan had previously pledged about $1.6 billion to charitable endeavors, according to a spokeswoman for the family.

“Having this child has made us think about all of the things that should be improved in the world for her whole generation,” Mr. Zuckerberg said in a video. “The only way that we reach our full human potential is if we’re able to unlock the gifts of every person around the world.”

Mr. Zuckerberg and Dr. Chan have recently made visible investments and gifts in several kindergarten-through-high-school education projects.

In May, AltSchool, a private school start-up in San Francisco that develops personalized learning technologies, announced that it had raised $100 million from a group of investors, including a donor-advised fund financed by the Zuckerberg family at the Silicon Valley Community Foundation.

In September, Facebook announced that it was working with Summit Public Schools, a charter school network, to develop an online platform to help tailor education to the needs and interests of individual students.

In November, EducationSuperhighway, a nonprofit group that helps K-12 schools tap federal funds for high-speed classroom Internet connections, announced that the couple had agreed to donate $20 million to its work.

Mr. Zuckerberg and Dr. Chan have also given to health care causes, including a $75 million gift to San Francisco General Hospital, which was renamed in their honor.

The ultimate value of the Zuckerberg family’s charitable pledge is unknown. Mr. Zuckerberg and Dr. Chan intend to gradually transfer their Facebook stock or the proceeds from stock sales to the Chan Zuckerberg Initiative.

If Facebook shares continue to appreciate, the value of the gift could be much higher than the current estimate of $45 billion.

Michael R. Bloomberg, the former mayor of New York and a billionaire as well, also applauded Mr. Zuckerberg’s announcement and said he shared the Facebook executive’s interest in education and innovation.

“The only question now is: How many of his peers in Silicon Valley and beyond will join him?” Mr. Bloomberg said.(VINDU GOEL and NICK WINGFIELD)