This can be caused by many things. Here are things to check:
Washer vibration can occur if the support bracket is broken. Check the bracket for any damage or wear, replace as needed.
Washer vibration can occur if one or more of the shock absorbers is broken or worn out. Check the absorbers to be sure they are installed correctly and in the right position. Sometimes when a washer is moved the shock absorbers separate and have to be put back together. If they are broken or worn out, replace all at the same time.
Washer vibration can occur if one or more suspension rods are broken. Check all four rods, replace any that are broken.
Washer vibration can occur if one of the suspension springs has broken. Check all of the springs, if any are broken replace all of them at once.
Counter Balance Spring
Washer vibration can be caused by a broken counter balance spring. This washer is equipped with one or more counter balance springs which help to absorb the natural movement of the spinning tub. If a counter balance spring fails the tub might lean in one direction more than another and it will shake and cause vibration. The springs can be replaced but before purchasing the spring check to see if the place the spring attaches is OK. Sometimes the frame where the spring attaches has rusted out, making the repair more difficult and expensive.
Washer vibration can occur if the snubber ring is worn out or cracked. Replace as needed.
Washer vibration can occur if the snubber pad is worn out, missing, or coated with anything sticky. Replace if it's worn out or missing.
Washer vibration can occur if the snubber is worn out. If the snubber is worn out replace it.
If the washer has excessive vibration, the balance ring may have lost its fluid. The balance ring sits on top of the outer tub and helps to counter the force of the spin cycle. If the fluid leaks out of the balance ring the washer tub will be too heavy for the suspension system and cause the machine to vibrate and shake.
Washer vibration can be caused by a worn out or broken drive block or bell. The drive block connects the transmission with the agitator, if it's loose or broken the agitator can wiggle back and forth during spin and cause vibration
Rear Drum with Bearing
If the washer has a bad vibration in spin the rear drum with bearing might need to be replace. On this washer the bearing is not sold separately, the entire rear drum will have to be replaced. This is a very involved repair and will require disassembling most of the washer. However, if this is the problem it is going to get worse very quickly and so either the drum and bearing will need to be replaced or the washing machine.
Washer vibration can occur if one of the leveling legs is out of adjustment. Using a carpenters level on the top of the machine, be sure to adjust each leg until the machine is level side to side and front to back. Once the machine is level, tighten the lock nuts, if equipped, on the leveling leg threaded bolt against the body of the washer to keep them from changing height.