The Pentagon's top official for Asia-Pacific affairs, Randall Schriver, says Mattis described the talks as "straightforward and candid". In the South China Sea, tensions have been running high as the USA challenges China through freedom-of-navigation operations, bomber overflights, and joint drills with regional partners - all aimed to counter China's expansive but discredited territorial claims.
US Defence Secretary Jim Mattis was also there.
U.S. President Donald Trump has often lambasted China over its economic policies.
A meeting between Mattis and Wei was supposed to take place in Beijing last weekend, but it fell through after China declined to make Wei available.
China and Southeast Asian states will hold their first joint maritime exercises next week, officials said Friday, in a move aimed at easing tensions but which may spark USA alarm.
Southeast Asian countries agreed on Friday to guidelines to manage unexpected encounters between their military aircraft, with host Singapore calling the pact a world first and saying they would encourage their global partners to join.
Schriver had told reporters on Wednesday that the Chinese had requested the Singapore meeting with Mattis.
Top Chinese and US military officials have recently made a decision to sit down and try to mend fences in order to cool down the growing tension between two of the world's superpowers.
Mattis, speaking to reporters as he flew to Asia this week, rejected Chinese claims that the United States was acting aggressively and pointed the finger at Beijing.
"What we want in terms of stability are regular interactions at senior levels so we have a good understanding of one another's intentions, that we have confidence-building measures that will help us prevent an unintended accident or incident", Schriver said.
As recently as June, when Mattis was in Beijing for his first visit to China as Pentagon chief, President Xi Jinping called the U.S.
Military-to-military ties have always been one of the more fragile parts of the overall U.S.
"The militaries from both sides need to work hard together to increase strategic communication, manage security risks, expand fields of cooperation, and push forward the healthy and stable development of military-to-military relations". That action was taken under the Countering America's Adversaries Through Sanctions Act passed by Congress in 2017. Beijing, Taiwan, Vietnam, Malaysia and the Philippines have staked claims over elements of the Spratlys, while Beijing, Taiwan and Vietnam dispute sovereignty over the Paracels. Earlier this month, a Chinese vessel had a naval altercation with a US destroyer near the highly disputed Spratly Islands.
"As we speak, the navies of ASEAN are en route to Zhanjiang in China for the ASEAN-China Maritime Exercise", Singapore Defence Minister Ng Eng Hen said.
"If we can have that sort of activity going on, it's transparent, something that's been lacking in the South China Sea". US Navy ships conduct "freedom of navigation" operations in these areas, though, and US Air Force bombers sometimes conduct "flyovers" over the South China Sea.