Donald Trump is to visit Mexico on August 31, hours before he details measures against illegal immigration in a speech.
The Republican presidential nominee tweeted that he was looking forward to meeting Mexico’s President Enrique Pena Nieto, who has invited both him and Democrat Hillary Clinton.
President Enrique Pena Nieto said dialogue would help “protect Mexicans wherever they are”.
The Republican will visit Mexico in between a fundraising event in California and his immigration speech in Phoenix, Arizona, on Wednesday night.
Donald Trump has seen his poll ratings slip since the party conventions last month.
Both nationally and in key states, Donald Trump trails Hillary Clinton, who enjoys particularly strong support among minorities.
Enrique Pena Nieto said he had invited both candidates for talks and would meet Donald Trump in private on August 31.
“I believe in dialogue to protect Mexican interests in the world and, principally, to protect Mexicans wherever they are,” the Mexican president said.
Hillary Clinton’s campaign has not yet said if she will travel to Mexico.
Enrique Pena Nieto has previously accused Donald Trump of hurting US-Mexico relations and compared the Republican’s rhetoric to that of German Nazi leader Adolf Hitler.
Donald Trump has threatened to stop cash sent home by Mexicans based in the US until the country pays for the wall.
He blames Mexico for the disappearance of jobs from the US, with companies choosing to locate south of the border to take advantage of cheaper labor costs.
In June, Donald Trump expressed anger after a leading golf tournament was moved from one of his courses to Mexico, accusing the PGA Tour of putting “profit ahead of thousands of American jobs”.