Good morning, jennper.
This article has some good troubleshooting steps for you. It's titled for OS X Mountain Lion, but the steps are universal for all post-2006 Mac.
As it mentions in the last bit of that acticle, you may need to have your battery serviced. If so, you can follow this link to contact Apple Support or find a service center near you.
Enjoy your day!