Hillary Clinton raised more than $40 million for her presidential campaign in June, a healthy sum as the presumptive Democratic nominee seeks to maintain her overwhelming fund-raising and organizational advantage against Donald J. Trump.

The Clinton campaign said Friday that it was beginning July with more than $44 million in cash on hand, as it starts to advertise heavily in battleground states in an attempt to define the race against Mr. Trump, who has not challenged Mrs. Clinton on the airwaves. He began June with only $1.3 million cash on hand and has focused in recent weeks on adding to his coffers.

Mrs. Clinton also raised about $28 million for the Democratic National Committee and state parties, her campaign said.

“Our first month of general election fund-raising proved to be the best of the campaign,” Robby Mook, Mrs. Clinton’s campaign manager, said in a statement. “Thanks to the continued support of nearly 1.6 million people, we have been able to help Democrats build out an organizing infrastructure across the country that will mobilize millions of voters and help elect progressive candidates up and down the ballot.”