I recommend spending at least a week in Costa Rica. This will give you enough time to spend three nights on one of the coasts and four nights in the rainforest interior.
Costa Rica is a tropical country with a generally pleasant climate. But temperatures vary depending on elevation. And you’ll always want a rain jacket with you.
The coastal areas tend to be warmer throughout the year, while the mountainous interior can get cool at night and in the early mornings, even during the summer months.
So, if you’re visiting during the rainy season, bring warm clothes and layers everywhere you go, even to the coasts. If you’re visiting during the dry season or summer, still bring a couple of layers for the evenings and mornings in the higher elevations.
If you’re doing any treks or hikes in either season, make sure you have any specialized clothing or equipment you might need.
Electrical outlets in Costa Rica are Types A and F. So, if you’re from the U.S., you won’t need an outlet adaptor. But British, European, and other travelers will need an adaptor.
I applied bug spray every day and still got some bites, so I recommend always having a can with you.