Why did US declare war with Spain in 1898?

The US sent the battleship USS Maine to protect the lives and property of American citizens. The ship remained quietly at anchor in Havana Harbor for 3 weeks. Then, on February 15, 1898, an enormous explosion shattered the Maine, killing about 260 officers and crew members. American newspapers immediately blamed Spain. Much later evidence indicated that the explosion may have been accidental, but at that time, Americans clamored for war with Spain.