The match, which will be held in the 66,000-capacity Workers Stadium on May 25, is part of the Winoly Cup International Football Tournament.
Ajax marketing manager Edwin van der Sar welcomed the chance to close the season in China.
He said: "It's fantastic for our name and our brand that we go to China.
"It's a very large country with enormous potential. Therefore we are pleased that we are invited to play this game.
"We will travel with as strong a squad as possible to Beijing.''