Taiwan's foreign minister, James Huang, initially offered to resign to take responsibility for the issue, which leaves Taiwan with diplomatic ties with just 24 nations, compared to China's 170.
Confirming the Costa Rican decision Huang raised Taiwan's two great diplomatic setbacks of the past 58 years - the loss of its seat at the United Nations in 1971, and the ending of formal ties with Washington in 1979.
But he added Taiwan would weather the storm, saying: "The more we are beaten down, the braver we get."
Chen Shui-bian, Taiwan's president, later rejected Huang's resignation offer.
On May 25, Huang met officials from Costa Rica and four other Latin American countries in Belize City in an effort to shore up Taiwan's diplomatic standing in the region.
Huang said China had offered Costa Rica "an astronomical figure" to ditch ties with Taipei, but did not go into specifics.
"I've asked our embassies to take extreme precautions against any further pressure by the Chinese communists," he said.
At its peak in 1969, Taiwan had full diplomatic relations with 67 countries
UN shifted recognition from Taiwan to China in 1971
Washington severed foirmal ties in 1979 when it established relations with Beijing
Taiwan is officially recognised by 24 states, mostly small nations such as Solomon Islands and Nicaragua
Others, including the US, Japan and Britain, maintain semi-official ties
Announcing the switch of ties, the Costa Rican president said economics was the overarching reason for the move.
Noting that "China is the most successful emerging economy in the world", Arias said Costa Rica was "looking to strengthen the commercial ties and attract investment".
"Taiwan has been very generous and I thank it for the solidarity and co-operation it has shown for nearly 60 years, but I have taken this decision thinking of all the Costa Ricans."
Arias said China is the Central American nation's No. 1 trading partner, buying more than $1bn worth of Costa Rican exports last year.
Welcoming the new diplomatic ally, a spokeswomen for China's foreign ministry said Beijing was urging other Latin American states with ties to Taiwan to follow Costa Rica's move.
"We hope the relevant countries can follow the trend of the times and make the right choice," Jiang Yu told reporters.
China and Taiwan are believed to spend heavily to get diplomatic recognition, offering investment, loans and other incentives.
Central America in particular has given Taiwan strong support and Taipei had expressed fears that if Costa Rica were to switch sides, other nations such as Nicaragua and Panama could soon follow suit.
Since splitting amid civil war in 1949, Taiwan and China have fought to win the diplomatic allegiance of countries around the world.
Under what it calls its "One China Policy" Beijing refuses to have diplomatic ties with nations that recognise Taiwan.
According to Beijing, Taiwan is a renegade province it plans to eventually unify with the mainland, and has threatened to use force against the island if it makes any moves toward formal independence.