At first blush, Argentina seems like an odd choice of partners for the Islamic Republic of Iran. The South American nation holds the dubious distinction of being the first victim of Iranian terrorism in the Western Hemisphere, suffering terrorist attacks on Israeli and Jewish targets in Buenos Aires that were carried out by Iranian-sponsored radicals in 1992 and 1994. Yet today, relations between Argentina and Iran are unmistakably on the upswing.

In the past two years, the government of Argentina’s leftist President Cristina Fernandez has broken with tradition and increasingly hewed a more conciliatory line toward Iran. This is manifested in growing bilateral trade (totaling some $1.5 billion in 2010), and a more sympathetic diplomatic stance from Buenos Aires. Last September, for example, Argentina’s envoy to the United Nations pointedly broke with previous practice and remained seated during Iranian President Mahmoud Ahmadinejad’s inflammatory General Assembly address.

Officials in Buenos Aires still formally insist that their country has no interest in overly close relations with Iran and little appetite to import the sort of problems that are commonly associated with close cooperation with Iran. They also allude to Iranian complicity in the 1992 bombing of the Israeli Embassy in Buenos Aires and the bombing of the Argentine-Israeli Mutual Association there two years later, as a lasting impediment to contacts with Tehran.

Yet there is a sense among opposition politicians in Argentina that the Fernandez government is eager to turn the page on the now 29-year-old investigation into the Argentine-Israeli Mutual Association bombing. In this regard, Iran’s fall 2011 overture to assist with the probe, although a patently empty promise, may have provided an excuse for Buenos Aires to begin a qualitative betterment of ties with Tehran.

A number of other factors also have contributed to Argentina’s recent flirtation with the Islamic Republic.

One is economics. Argentina is now weathering a significant financial downturn, one brought about by the global economic recession and by the Fernandez government’s own anti-free-market policies. All of this gives trade with Iran greater salience for Argentina than would otherwise be the case. Indeed, bilateral trade has grown to the point that Argentina now ranks as Iran’s biggest economic partner in Latin America.

Another is Argentina’s international outlook. Argentine officials make no secret of their government’s desire for an “independent” or “emancipated” foreign policy — a thinly veiled allusion to the need for political distance from the United States. This stance has predisposed the Fernandez government toward cooperation with Iran, as well as with other international actors such as China.

Perhaps most decisive of all, however, have been the machinations of Argentina’s principal foreign policy architect. Foreign Minister Hector Timerman, though Jewish, has publicly broken with Argentina’s sizable Jewish community to pursue ties with Iran (as well as with other Middle Eastern states that are antagonistic to Israel). Mr. Timerman, local observers say, is conducting what amounts to a “transactional” foreign policy, bartering Argentina’s international positions in return for political and economic dividends from foreign partners.

Thus, a failure to parlay cooperation with the United States on Iran into tangible rewards from America several years ago led Argentina to tilt the other way. As part of that reorientation, Mr. Timerman is said to have repeatedly visited Aleppo, Syria, in 2011, where he is believed to have met with Iranian Foreign Minister Ali Akbar Salehi to coordinate policy on a range of international issues.

At the end of the day, Argentina’s emerging relationship with Iran may simply be, as some observers have contended, a “cry for international attention” — an attempt by Buenos Aires to reclaim long-desired foreign policy dynamism and regional prestige. The growing strength of bilateral ties, however, could make it difficult for Argentina to keep the Iranian regime at arm’s length as it reaps the benefits of this engagement. If that ends up being the case, Argentina could find itself dancing a dangerous tango indeed.