If the engine is not actually overheating when this is happening, then we could be looking at a few different things.
You could have a big air pocket in your system.
Your radiator cap could be bad
Too much pressure in the cooling system (caused by a bad head gasket)
Cooling fan or fans not coming on for some reason.
Or the engine is overheating and the temp gauge is not reading accurately.