The world's richest person announced the share giveaway, which is worth a total of about $US18 billion ($A27 billion), on the eve of Thanksgiving and just hours after SpaceX won US approval on Wednesday to deploy one million satellites for data centres in space.
Musk is seeking to expand SpaceX's role in the AI industry, even as the rapid growth of computing infrastructure raises concern about its environmental impact and the economic and political influence of technology billionaires.
Opponents of data centre development were among the biggest winners for the Democrats in November's US midterm elections.
Children would receive one share from SpaceX and one from him personally, Musk said in a brief post on X.
In a separate post, Musk said the SpaceX company shares would be transferred in December.
"The share directly from me will be transferred when my lockup expires in June next year," Musk said.
SpaceX said earlier on Wednesday it would contribute one newly issued share of its Class A common stock to every currently active Trump Account, adding that Musk would personally match the number of shares donated by the company.
A Trump Account is a program designed to give Americans under the age of 18 a stake in the stock market and help build wealth from an early age.
The White House said in October it had opened almost 70 million accounts.
SpaceX shares closed at $US127.44 on Wednesday, valuing the pledge at nearly $US18 billion.
SpaceX did not respond to a request for comment on whether Musk's SpaceX share donations would be linked to Trump Accounts.
Musk, whose net worth is around $US824 billion, said in October he would give one of his SpaceX shares to every child in America.
He held about 6.42 billion shares in the company as of June.
"Next year, I will give one of my SpaceX shares to every kid in America. This will be the first of many," Musk said in a post on X at the time.
"Giving shares, which are stakes in the future economy, directly to the people is the way," said Musk, most of whose philanthropic efforts have been through the Musk Foundation, which reportedly holds more than $US14 billion in assets.