Of course, make sure the appliance is unplugged.
The old capacitor might hold a charge. While not dangerous, a shock from a motor start capacitor can be pretty nasty and hurt a lot.
So, before takeing it out, short out its contacts with something metal with an insulated handle (screwdriver or such).
Not sure if these capacitors have a polarity, but just in case:
1) Take photos of the capacitor while still connected to all leads.
2) Carefully compare the old and new capacitor and check if there are any markings like + and - signs, numbers or letters corresponding to a certain wire.
3) If there are any markings indicating a certain way of hooking the capacitor up, then follow these exactly and before connecting the machine to the power make 100% you correctly wired it in. If that capacitor has a demanded polarity, hooking it up in reverse will most likely blow up the capacitor, and cleaning that mess isn't nice.
The terminals that connect the capacitor to the wires can be quite annoying to undo and might require some force. There might even be small hooks on them that you have to depress to be abled to remove them.
A pait of pliers can help.
Just be carefull not to pull and tug to much on the cables to prevent any damge or wonky connections further within the machine.
Before closing up the machine, run a short test cycle checking that everything works. Just be carefull not to touch the machine in case something accidently shorted to the cabinet.