When the 14th quadrennial Central American and Caribbean Games began here Saturday, President Fidel Castro played host at the opening ceremonies, a gesture reflecting the importance Cuba attaches to being the site of a major event in this sports-loving region.

But the gesture had political implications, too, as Castro briefly posed in a golf cap emblazoned with the flag of Puerto Rico, whose independence from the United States is a cause Cuba long has supported.

That cause, and Castro's image on the nearby island, may have been given at least a symbolic boost this week by nearly 200 Puerto Rican sports fans. They traveled here to cheer their teams in apparent defiance of a Reagan administration ban on U.S. tourist travel to Cuba -- a prohibition they say is unfair, ineffective and maybe even unconstitutional.

As the fans' days of baseball and beer-drinking, decathlon and daiquiris slip by, it remains unclear what the administration will do about the defiant Puerto Ricans, whose number includes several politicians who hope to make some political hay of their own out of the visit.

In the meantime the ban, announced April 19 as part of the administration's toughening line with Cuba, has given Castro a broad wedge into Puerto Rican affairs that he could hardly have bettered by design.

In the days since the games opened, Castro has had a major opportunity to reassert his "solidarity" with the people of Puerto Rico, playing on historical, cultural and linguistic ties that have bound the two islands together for centuries.

One Puerto Rican politician who has received an especially warm reception from Cuban officials -- whom he described as "extremely courteous" -- is Ruben Berrios, 43, head of the Puerto Rican Independence Party. Berrios considers himself a social democrat and has spent more than a dozen years steering clear of communism and forcing Marxist-Leninists out of his party.

Although Berrios' party worked with the Cubans at the United Nations to push through resolutions supporting Puerto Rican independence, Berrios had never come to Castro's Cuba.

Now that he is here, being escorted by Cuban Deputy Foreign Minister and former U.N. ambassador Ricardo Alarcon, Berrios is telling the local press that the ban demonstrates Washington's "colonial domination" of Puerto Rico.

Carlos Gallisa, head of the minuscule Marxist-Leninist Puerto Rican Socialist Party and a freqent visitor here, has, by comparison, received very little attention.

But both Gallisa (who has two sons competing in the rowing events) and Berrios appear to be looking for a similar end to their Cuban sojourns: a confrontation with Washington.

"I couldn't get permission, but neither did I want to get permission," said Gallisa as he sat in the baseball stadium Sunday.

Berrios embraces this as "an even better opportunity" for civil disobedience than his much publicized arrest for occupying the U.S. Navy firing range at Culebra in 1970.

While not all the Puerto Rican tourists who made the commitment to come here are happy with the prospect of controversy, few fail to express resentment about the ban itself.

Edwin Pagan Rodriguez, a retired lawyer from San Juan who has watched Puerto Rico's teams compete all over the world, complained about the ban that conceivably could have him facing 10 years in jail and a $10,000 fine when he gets back: "It isn't fair. I don't agree with Fidel about anything. But this just isn't fair. I'm not interested in politics here. What interests me is sport."

In Washington, a Justice Department spokesman said the State Department would be consulted before a decision on prosecuting the group in Havana would be taken.

It was German Rieckehoff, the conservative head of the Puerto Rican Olympic Committee, who gave Castro the cap to wear at the opening ceremonies, according to spectators seated nearby. Pictures of Castro sporting it appeared in many Puerto Rican papers.

What many of the Puerto Ricans find particularly galling about the ban, and a point played on heavily by the politicians, is the sense that the action, under the 1917 Trading With the Enemy Act, appears to have applied to almost no one else.

Actually, the ban is a reimposition of the one relaxed in 1977 by the Carter administration during an effort at U.S. rapprochement with Cuba. Since then, most U.S. visitors to Cuba have been relatives of people still here, according to diplomats in Havana. Under the Reagan ban, these people can still come.

Another substantial group of American visitors is made up of officials and journalists. These are not affected by the ban either, and as recently as June a group of 120 American intellectuals received permission to come for an international conference. Hundreds of athletes and reporters from the U.S. Virgin Islands and Puerto Rico are here for the games with no problem.

There is some speculation among the Puerto Ricans here that Washington will try to sidestep the issue, perhaps by determining that, through one loophole or another, most of the 186 tourists the politicians say are here in defiance of the Reagan ban were really legal.

[The Puerto Rican Olympic Committee obtained a special license from the U.S. government for the athletes, their coaches and associated personnel, plus about 36 local politicians from Puerto Rico, to attend the games. But a license was refused for spectators for whom the committee had contracted with Cuba a year earlier, said Harvey Nachman, a lawyer in Puerto Rico who acted for the committee's court challenge of the refusal.]