U.S. citizens need only a passport to enter Costa Rica and a return plane ticket home or to another country for stays of up to 90 days. Make sure it's up to date. We've received much conflicting information, even within officialdom, about how long your passport must be valid—government officials, passport officers, and airline check-in agents seem to interpret the rules differently. To be on the safe side, make sure your passport is valid for at least six months. Renew it before your trip if it is not. Spending 72 hours outside the country—Nicaragua or Panama are popular options—gets you another 90 days, but don't expect to do that undetected more than a couple of times. Customs forms ask how many visits you've made to Costa Rica in the past year.
Costa Rica has one of the highest rates of U.S.-passport theft in the world. Travelers in Costa Rica are not required to carry their original documents with them at all times, although you must have easy access to them. Photocopies of the data page and your entry stamp are sufficient; those, at least, must be with you at all times. Although there have been reports from around the world about security problems with in-room safes, if your hotel doesn't have a safe in reception, locking a passport in a hotel-room safe is better than leaving it in an unlocked hiding place or carrying it with you.
For easy retrieval in the event of a lost or stolen passport, before you leave home scan your passport into a portable storage device (like an iPod) that you're carrying with you or email the scanned image to yourself.
If your passport is lost or stolen, first call the police—having the police report can make replacement easier—and then call your embassy. You'll get a temporary Emergency Travel Document that will need to be replaced once you return home. Fees vary according to how fast you need the passport; in some cases the fee covers your permanent replacement as well. The new document will not have your entry stamps; ask if your embassy takes care of this, or whether it's your responsibility to get the necessary immigration authorization.