As a minimum you would also need to change the shifters. Possibly the derailuer and believe it or not, possibly also the chain.
If it was originally 7 speed, chances are it was a 'freewheel', ie the 7 cogs at the back were part of a single sprocket assembly. 8 speed up is generally (but not always) a cassette on a 'freehub'. This would be irrelevant to most, except that it seems modern dérailleurs are designed for one or the other, shifters are indexed to the gap width between cogs, and chains are also made to fit the exact width, so unfortunately upgrade is probably not as straight forward as it might sound.