Bashir is one of the foreign heads of state attending a huge military parade on Thursday to mark the 70th anniversary of Japan's surrender in World War II. Major western leaders have shunned the event.
The International Criminal Court (ICC) indicted Bashir over war crimes and crimes against humanity in 2009 and on genocide charges in 2010, all relating to the conflict in Sudan's Darfur region.
"You are an old friend of the Chinese people," Xi said after shaking hands with Bashir and a procession of Sudanese government officials accompanying him.
"China and Sudan are like two brothers that are also good friends and partners," Xi said.
More From This Section
China's foreign ministry defended itself against accusations that inviting an indicted war criminal to a parade billed as a celebration of peace was contradictory.
"China is not a signatory to the Rome Statute of the International Criminal Court," spokeswoman Hua Chunying told a regular briefing.
"African people including the people of Sudan made important contributions during the World Anti-Fascist War," she added, using the Chinese government's name for World War II.
"For Sudan and China, cooperation in politics, economics and culture and many more fields have all had good results," he told Xi before closed-door talks.
The US expressed concern on Monday over Bashir's trip to China, with State Department spokesman Mark Toner saying: "We oppose invitations, facilitation or support for travel by persons subject to outstanding ICC warrants."
Bashir last travelled to China, which has significant interests in Sudan's oil sector and supports his government, in 2011.
The Darfur conflict erupted in 2003 when ethnic insurgents rebelled against the Arab-dominated Khartoum government, complaining of marginalisation.