Turn off the hot tub and disconnect the power or turn off the breaker to ensure there isn't an electrical discharge during the valve replacement. The water should be off as well.
Remove the old diverter valve. On some models, the valve pulls right out of the main casing of the hot tub once the cap is removed, while on others you may need to unscrew it with a wrench or screwdriver.
The location of the diverter valve varies greatly depending on the hot tub model. Check your user manual if you don't know where to find it.
It looks like a three-way section of piping with a cylinder sticking out of it.
Insert the new valve into the opening where the old one was. It should slide into position and connect.
Secure the valve in place by either reinserting the screws or tightening the bolts you undid when taking the old valve out.
Place the cap back over the valve. Restore power and turn the water and the jets on to ensure the new valve works properly.