Only Malagasy citizens can travel to Madagascar without a visa. All other nationalities are required to have a visa upon entering Madagascar. You will need a passport that is valid for at least the next 6 months. It is about €40 for a one month tourist visa.
US citizens who do not wish to go through the trouble of dealing with the red tape themselves can count on the professional services of Travel Visa Pro to speed things up: Apply for Madagascar Visa Online (service starts from $39). If you need to renew, add pages, change name, or just get a new US passport, you can Apply for a New US Passport here.