[What you need to know to start the day: Get New York Today in your inbox.]
DES MOINES — When Mayor Bill de Blasio visited Iowa in February, he delivered a deluge of ideas about how his party could take back the White House. He also offered one main piece of political advice: Ignore President Trump.
“We’re not going to win by talking about Donald Trump,” Mr. de Blasio said.
But in the days leading up to the announcement of his presidential candidacy on Thursday, and during a trip to Iowa on Friday, Mr. de Blasio appears to have had a change of heart.
He held a raucous news conference at Trump Tower this week to attack Mr. Trump and to promote environmental legislation. Announcing his candidacy on the ABC program “Good Morning America,” Mr. de Blasio gave Mr. Trump a nickname: “Con Don.”
And on Friday, he put a particular Iowa twist on his criticism while he toured an ethanol plant with former Iowa Gov. Tom Vilsack.
“Time and again, when there’s an opportunity to help the biofuels industry grow and to create jobs in places like rural Iowa, the Trump administration has favored big petroleum companies and that has to end,” Mr. de Blasio said after he toured the plant and while he spoke with workers.
Mr. Trump responded on Thursday with an unusual attack on Mr. de Blasio, recording a short video clip in which he called Mr. de Blasio “the worst mayor in the history of New York City.”
“If you like high taxes and if you like crime, you can vote for him,” Mr. Trump said.
While taxes in New York are relatively high, the city is one of the safest in the nation, and the crime rate has remained low under Mr. de Blasio.
The president’s response seemed to affirm Mr. de Blasio’s strategy that one way to overcome the many obstacles that he faces in the race is to attract attention by focusing on Mr. Trump.
Mr. de Blasio entered the presidential race late, and was the 23rd Democrat to declare. He faces challenges in everything from fund-raising to staffing, not to mention standing out in a crowded field.
Many New Yorkers don’t believe he should run, and many of Mr. de Blasio’s closest advisers warned him to stay out of the race. On Friday, he raced around Iowa with three staff members, all of who were City Hall aides volunteering their time.
When asked how much money he had raised in the 24 hours since his announcement, the mayor declined to answer.
Mr. de Blasio will also be campaigning without the benefit of his two children, Chiara and Dante, who played important roles in his unexpected win in the 2013 mayoral race.
“Our children have their own lives. I can’t speak for them anymore,” said the mayor’s wife, Chirlane McCray, before Mr. de Blasio jumped in.
He said there was “no plan” for his children to take part in his presidential campaign in the “near term.” Mr. de Blasio will go straight from the campaign trail to Dante’s graduation from Yale University on Sunday.
Jim Crounse, who has handled direct mail campaigns for Hillary Clinton and who will serve as a senior adviser to Mr. de Blasio’s campaign, said they would iron out the bumps.
“It’s like any other campaign,” he said. “You start at the bottom.”
Mr. de Blasio will head to South Carolina on Sunday, where he will campaign in Columbia and Charleston.
The rockiness of the first trip was evident. A roundtable on mental health with Ms. McCray and Mayor Frank Cownie of Des Moines that was supposed to be open to the news media was unexpectedly closed.
Mr. de Blasio had hoped for a visit with the Asian & Latino Coalition PAC in Des Moines, a group he spoke to in February. But Prakash Kopparapu, the chairman of the group, said it could not accommodate Mr. de Blasio’s schedule.
“We asked around, and most of our members had different commitments,” he said.
Asked about Mr. de Blasio’s new approach toward Mr. Trump, Mr. Kopparapu said Mr. de Blasio had no choice but to take on the president.
“There are 25 candidates — you have to stand out,” Mr. Kopparapu said. “Your best thing is to go up against the most popular person. Fox will run his Trump comments and so will MSNBC. It’s a marketing strategy.”
But the mayor also has to present innovative policies, he said.
“When someone is a candidate this late in the game, and we have already met a lot of candidates, we expect specifics,” Mr. Kopparapu said. “When you say Medicare for all, how are you going to do that?”
After visiting the ethanol plant, Mr. de Blasio drove to Churdan, where he met with 10 small farmers. They talked about tariffs and other challenges that prevented farmers in the area from growing.
Mr. de Blasio, who has adopted the campaign theme of “Working People First,” spoke about income inequality, again lashing out at Mr. Trump.
“What I’m hearing you say is the system is rigged in favor of corporate agriculture,” said Mr. de Blasio, who was dressed in dark jeans, a white dress shirt and new Cole Haan shoes.
George Naylor, 71, and his wife Patti Naylor, 62, hosted Mr. de Blasio on their 320-acre farm, which has been in his family for 100 years.
Mr. Naylor said Mr. Trump was a symbol of the problems in this country.
“Money tends to go to the rich people and the multinational corporations, instead of the people doing the work,” he said, before voicing a caveat about the mayor’s approach.
“Trump is a loose cannon,” he said. “The mayor needs to be crystal clear about what’s wrong with Trump instead of just demonizing him.”