8 Ohm Speaker Gets Hot - Simple 555 Piano
An ordinary 8 ohm speaker has a coil of wire inside, which will get hot if you pass a DC current through it.  The DC resistance is likely to be considerably less than the nominal 8 ohms impedance to AC.  By switching the output between 0V and (approximately) the battery positive, you are - on average - applying a significant voltage across the speaker.

It's normal in such circuits to place an electrolytic capacitor in series with the speaker to block the DC and let through only the AC signal.  Make sure the capacitor is the right way round.

A rough back-of-an-envelope calculation says about 470 microfarad or more for the capacitor.  That gives less than 2 ohms impedance at 200 Hz (and lower still at higher frequencies).  We want the impedance to be significantly less than that of the speaker.  Impedance = 1/(2 π f C), where f is the frequency and C the capacitance.