Real Estate Capital Gains in Costa Rica: When You Pay 15%, When You Pay 2.25%, and When You Pay Nothing

What Every Real Estate Owner, Investor and Foreigner Must Know

Selling property in Costa Rica can be one of the smartest financial moves you make… or one of the most expensive mistakes of your life if you do not understand how capital gains tax really works.

Every year we see sellers lose tens — sometimes hundreds — of thousands of dollars. Not because Costa Rica is a high-tax country, but because they did not structure the transaction correctly or relied on “what everyone does” instead of what the law actually says.

The truth is simple: Costa Rica’s real estate tax system is favorable — but it does not forgive improvisation.

What Is Capital Gains Tax in Costa Rica?

Under Costa Rican law, capital gains tax is generally taxed at 15% on the net gain, meaning the profit obtained from the sale. This regime was formally introduced by Law No. 9635 (Ley de Fortalecimiento de las Finanzas Públicas) and applies to transfers of real estate located in Costa Rica.

The taxable gain is not the sale price. It is the difference between the acquisition value and the transfer value, after deducting legally admissible costs. These deductions are not automatic. They depend entirely on documentation and on how the transaction and the property history were structured over time.

Who Is Subject to Capital Gains Tax

Capital gains tax in Costa Rica is governed by the principle of territoriality. The relevant factor is not the seller’s nationality or immigration status, but the fact that the asset is located in Costa Rica.

A Costa Rican citizen, a permanent resident, a temporary resident, or a foreigner with no residency are subject to the same substantive tax rules when selling Costa Rican real estate. There is no preferential treatment or penalty based on passport or residency.

General Rule: 15% on the Net Capital Gain

As a general rule, the sale of real estate generates a taxable capital gain subject to a 15% tax on the net profit. The law allows the seller to deduct properly supported acquisition costs, formal improvements, construction, and other expenses directly linked to the acquisition or enhancement of the asset.

In practice, many sellers overpay simply because improvements were never formally declared or documented, or because the transaction is analyzed only at the closing stage, when there is little room to correct structural issues.

Transitional Regime for Properties Acquired Before July 1, 2019

Costa Rican law established a transitional regime for properties acquired before July 1, 2019. For these properties, the seller may elect, in the first transfer after that date, to apply an alternative tax treatment.

Instead of calculating the net gain and paying 15% on the profit, the seller may opt to pay 2.25% of the sale price. This is a final tax, not a withholding, and it is expressly contemplated by the law.

This option is not automatic. It must be consciously chosen, it only applies to qualifying properties, and it only applies in the first sale after the law entered into force. When properly applied, it can significantly reduce the tax burden. When misapplied, it can create future exposure.

Why There Is Confusion Around “Paying 2%”

A large part of the confusion comes from mixing two different legal concepts.

On one hand, there is the 2.25% optional final tax for pre–July 1, 2019 properties.
On the other hand, Costa Rican tax law also establishes withholding obligations (“retenciones”) in certain real estate transfers, particularly when the seller is not tax-domiciled in Costa Rica. In those cases, the buyer may be required to withhold a percentage of the sale price as a payment on account of the seller’s tax obligations.

These are not the same thing.
The withholding is not necessarily the final tax, and the 2.25% regime is not a withholding. Treating them as interchangeable is one of the most common — and costly — mistakes we see.

The Real Legal Exception: Casa de Habitación

Costa Rican law does recognize a specific and limited exemption from capital gains tax: the sale of a casa de habitación.

When the property sold qualifies as the seller’s primary residence, and the legal requirements established by tax law are met, the gain derived from the sale is not subject to capital gains tax.

This exemption does not apply automatically. The property must truly be the seller’s habitual residence, not an investment property, rental unit, vacation home, or speculative asset. The burden of proof rests on the taxpayer, and improper use of this exemption can lead to reassessments and penalties.

Outside of this scenario, capital gains tax applies.

Why Transaction Planning Matters More Than the Rate

Most financial mistakes in Costa Rican real estate do not come from the tax rate itself, but from lack of planning.

Accepting a price, signing an option agreement, or structuring payment terms without understanding which tax regime applies can lock the seller into an unnecessary tax exposure. In Costa Rica, the correct moment to analyze capital gains tax is before the transaction is formalized, not at closing.

How Magma Legal Costa Rica Adds Value

At Magma Legal Costa Rica, we analyze whether a transaction falls under the 15% net gain regime, qualifies for the 2.25% transitional option, or benefits from the casa de habitación exemption. We review acquisition history, improvements, and documentation, and we structure the transaction accordingly.

Our role is not to eliminate taxes unlawfully, but to ensure that the tax applied is the correct one under Costa Rican law, no more and no less. Real estate is built with time, effort, and faith. The tax outcome should reflect that reality, not punish lack of information.

If you are considering selling or acquiring property in Costa Rica, a legal review before signing can be the difference between a clean transaction and a very expensive mistake.