
Sexual Offenses & Age of Consent
Age of Consent and Sexual Offenses in Costa Rica: Protection of Minors, Trafficking, Bigamy and Public Decency
In short
Costa Rica's Penal Code treats any sexual intercourse with a child under 13 as rape. Since Law 9406 of 2016, sexual relations with a 13- or 14-year-old are a crime if the adult is five or more years older, and with a 15- to 17-year-old if the adult is seven or more years older; relatives, guardians and people in a position of trust are always liable. Paying a minor for sexual acts, sex tourism promotion, trafficking and any material sexualizing minors are serious crimes, and marriage under 18 is prohibited.
The short answer
Costa Rica protects minors from sexual exploitation through a detailed set of rules in its Penal Code (Law 4573), the Family Code and special laws such as the Law against Trafficking in Persons (Law 9095 of 26 October 2012). The law does not use a single "age of consent" figure. Instead it combines an absolute floor of 13, age-gap rules for adolescents and a strict rule for anyone in a position of trust. Adulthood starts at 18.
This page summarizes those rules factually, explains the related offenses that visitors and residents ask about (sex tourism, material involving minors, bigamy, public nudity) and lists where to report. It is general information, not legal advice.
Age of consent: how the Penal Code works
Under 13: always a crime
Article 156 of the Penal Code classifies as rape (violación) any sexual intercourse with a person under 13, whatever the circumstances, and punishes it with 10 to 16 years in prison. The same article covers victims who are vulnerable or unable to resist and cases involving violence or intimidation. Consent is legally irrelevant at this age.
13 to 17: the Law 9406 age-gap rules
In late 2016 the Legislative Assembly approved Law 9406 of 30 November 2016, titled Fortalecimiento de la protección legal de las niñas y las adolescentes mujeres ante situaciones de violencia de género asociadas a relaciones abusivas. It is widely known as the "relaciones impropias" (improper relationships) law. It rewrote article 159, which now punishes sexual relations with a minor, when they do not amount to rape, in three situations:
| Situation | Penalty |
|---|---|
| The minor is 13 or 14 and the other person is five or more years older | 3 to 6 years in prison |
| The minor is 15, 16 or 17 and the other person is seven or more years older | 2 to 3 years in prison |
| The other person is a relative (parent or other ascendant, uncle or aunt, sibling, cousin), a guardian, or holds a position of trust or authority over the minor or the family, related or not | 4 to 10 years in prison |
The practical message is simple: for adults, sexual contact with anyone under 18 carries serious criminal risk, and the age-gap rules exist mainly to avoid criminalizing relationships between peers.
Other offenses protecting minors
- Sexual abuse of minors (article 161): abusive acts with sexual purposes against a minor, short of rape, carry 3 to 8 years, rising to 4 to 10 years when the victim is under 15 or the offender is a relative, guardian, teacher or someone abusing trust.
- Paid sexual acts with minors (article 160): paying, promising to pay or giving any advantage to a minor or a third party so that a minor performs sexual acts is punished with 4 to 10 years if the minor is under 13, 3 to 8 years if 13 or 14, and 2 to 6 years if 15 to 17.
- Corruption of minors and online grooming (articles 167 and 167 bis): promoting a minor's involvement in erotic or pornographic displays is punished even if the minor agrees. Establishing sexual or erotic communications with a minor by any means is punished with 2 to 4 years, rising to 3 to 5 years if the offender tries to arrange a meeting. These texts were updated by the anti-grooming Law 10020 of 2021.
- Disqualification (article 161 bis): in any sexual crime against a minor, judges may add absolute disqualification for the full term set in the sentence.
No marriage under 18
Law 9406 also amended the Family Code. Article 14 now makes marriage of a person under 18 legally impossible, and article 64 orders the Civil Registry not to register it. Parental consent no longer opens an exception.

Sexual exploitation, sex tourism and trafficking
Costa Rica criminalizes the commercial sexual exploitation of people heavily, with additional protection for minors:
- Sex tourism (article 162 bis): promoting or running programs, campaigns or advertising that present the country as a destination accessible for commercial sexual exploitation or prostitution of people of any sex or age carries 4 to 8 years in prison. Law 9095 added this article in 2012.
- Pimping (article 169): promoting, inducing, keeping someone in, or recruiting for prostitution, or holding someone in sexual servitude, carries 2 to 5 years.
- Trafficking in persons (article 172): recruiting, transporting, harbouring or receiving people for sexual exploitation, forced labour and other listed purposes, using coercion, deception, abuse of vulnerability or payments, is punished with 6 to 10 years, rising to 8 to 16 years when the victim is under 18, among other aggravating circumstances.
- Establishments (article 175 bis): owners, landlords or managers of a place used for, or benefiting from, trafficking face 3 to 5 years.
Law 9095 also created the national coalition against trafficking and migrant smuggling (CONATT) and an immediate-response team, sets out victim-protection principles and, in article 30, directs complaints to the Public Prosecutor's Office or the Judicial Investigation Agency (OIJ), with the victim's identity kept confidential. Its article 35 bis promotes the "Blue Heart" anti-trafficking campaign in businesses, especially in tourism.
Distance offers no shelter. Under article 7 of the Penal Code, Costa Rican law applies to sexual crimes against minors and to taking part in the trafficking of women or children, regardless of where the acts were committed or the offender's nationality.
Material involving minors
Costa Rica's pornography rules focus on protecting minors:
- Production (article 173): making, producing, reproducing, disseminating or using material depicting minors in sexual activity carries 5 to 9 years. Inducing a minor to send sexual material is punished the same way, and bringing such material into the country carries 4 to 7 years.
- Possession (article 173 bis): possessing such material, including in local or cloud storage, carries 2 to 5 years.
- Distribution (article 174): showing or distributing pornographic material to minors carries 4 to 8 years; distributing or selling material in which a minor appears carries 5 to 9 years.
- Simulated material (article 174 bis): material using adults who pose as minors, or drawings or other representations that simulate minors, carries 6 months to 2 years.
The Penal Code does not generally criminalize lawful adult content between adults. However, secretly recording people with sexual connotation in public spaces or transport is a crime under article 175 quinquies, with higher penalties if the material is shared.

Is there a sex offender registry?
We did not find any law in force that creates a public sex offender registry like those in the United States. What exists:
- Criminal records. Convictions are entered in the Judicial Criminal Record under the Judicial Records Law (Law 6723). Since a 2024 reform, entries for sexual crimes against minors are cancelled only ten years after the sentence is served, and certificates requested for employment must show them while they remain in force. PANI, the migration authority, police recruitment offices and other bodies listed in article 13 can obtain certifications.
- Entry bans. Article 61 of the Migration Law bars foreigners who face precautionary measures or pending prosecution for sexual crimes against minors, or who served a sentence for such crimes within the last 50 years. The migration authority must check this and may sign information-sharing agreements with foreign authorities.
Bigamy
Costa Rica has bigamy rules, even though the Penal Code does not use that word. Article 14 of the Family Code makes marriage legally impossible for a person already bound by a prior marriage. The Penal Code then punishes:
- Illegal marriage (article 176): both parties who marry knowing of an impediment that causes absolute nullity, 6 months to 3 years in prison.
- Concealing the impediment (article 177): marrying while hiding such an impediment from the other spouse, 2 to 6 years.
- Officials (article 179): a public official who knowingly authorizes such a marriage faces the same penalty increased by a third.
Public nudity and indecent exposure
Two levels of rules apply:
- Minor offense (article 392): a person who appears naked or exposes their genitals in a public place, or performs indecent acts in a public place or in a private place exposed to view, faces 5 to 30 day-fines. - Crime (article 175 ter): masturbating, or exhibiting one's genitals with sexual connotation to another person without their consent, in a public space or paid transport, is punished with 6 months to 1 year in prison or 30 to 45 day-fines. Law 9877 of 2020 against street sexual harassment added this article.
How to report
- Immediate danger: call 9-1-1.
- Children at risk: contact the Patronato Nacional de la Infancia (PANI), whose website lists its children's line and complaint channels.
- Crimes: report to the Public Prosecutor's Office (Ministerio Público) or the Judicial Investigation Agency (OIJ). Trafficking complaints go to these bodies under article 30 of Law 9095.
Health workers, school staff, daycare staff and adults responsible for minors in organized groups have a legal duty to report reasonable suspicion of abuse under article 49 of the Children and Adolescents Code, and their identity must be protected.
Getting legal help
Sexual offense cases are complex and sensitive for victims, families and anyone under investigation. If you are dealing with a report, a protection process before PANI or criminal proceedings, consult a Costa Rican criminal or family lawyer promptly so that your rights and any child's interests are protected from the start.
Sources
- Ley 4573, Código Penal, arts. 7, 156, 159-162 bis, 167-175 quinquies, 176-177 and 392, SINALEVI
- Ley 5476, Código de Familia, arts. 14 and 64 (as amended by Law 9406 of 30 November 2016), SINALEVI
- Ley 9095, Ley contra la Trata de Personas y Creación de la CONATT (26 October 2012), SINALEVI
- Ley 8764, Ley General de Migración y Extranjería, art. 61 (as amended by Law 9177 of 2013), SINALEVI
- Ley 6723, Ley del Registro y Archivos Judiciales, arts. 11 and 13 (as amended by Law 10453 of 2024), SINALEVI
- Ley 7739, Código de la Niñez y la Adolescencia, art. 49 (duty to report), SINALEVI
- Patronato Nacional de la Infancia (PANI), official site
Frequently asked questions
What is the age of consent in Costa Rica?
There is no single number. Under the Penal Code, any intercourse with a child under 13 is rape. With a 13- or 14-year-old it is a crime if the other person is five or more years older; with a 15- to 17-year-old, if the other person is seven or more years older. Relatives, guardians and people in a position of trust or authority commit a crime with any minor. Adults are 18 or older.
What is the 'relaciones impropias' law?
It is the popular name of Law 9406 of 30 November 2016, which rewrote article 159 of the Penal Code with the age-gap rules, raised protections in the abuse article and amended the Family Code so that people under 18 cannot marry.
Is sex tourism illegal in Costa Rica?
Yes. Article 162 bis of the Penal Code punishes with four to eight years in prison anyone who promotes the country as a destination for commercial sexual exploitation or prostitution. Paying a minor for sexual acts, trafficking and running establishments that benefit from trafficking are separate crimes.
Does Costa Rica have a sex offender registry?
We found no law creating a public sex offender registry. Convictions go into the Judicial Criminal Record, which for sexual crimes against minors is kept for ten years after the sentence is served and can be certified to bodies such as PANI and the migration authority. Foreigners with such convictions in the past 50 years are refused entry.
Does Costa Rica have bigamy laws?
Yes. The Family Code makes marriage legally impossible for a person already married, and the Penal Code punishes knowingly marrying despite an impediment that causes absolute nullity (six months to three years) and hiding that impediment from the other spouse (two to six years).
Is public nudity illegal in Costa Rica?
Showing oneself naked in a public place is a minor offense punished with five to thirty day-fines under article 392 of the Penal Code. Exhibiting oneself with sexual connotation to someone without consent in a public space is a crime under article 175 ter.
How we can help
Costa Rica Litigation Lawyer
Costa Rica litigation lawyers for civil, commercial, property and administrative disputes: negotiation, conciliation, arbitration and court representation.
Costa Rica Family Lawyer
Costa Rica family lawyers for divorce, child custody and visitation, child support (pensión alimentaria), marriage, prenuptial agreements and foreign judgments.
Costa Rica Immigration Lawyer
Costa Rica immigration lawyer for residency applications, DGME requests, appeals, overstays, work permits and status changes, in English and Spanish.
Related Costa Rica laws
Talk to a lawyer
This page is general information about Costa Rican law. For advice on your own situation, book a consultation or send us a short question.
The information on this website is general information, not legal advice. Contacting us does not create an attorney-client relationship.


