How to control appliances with arduino?

Another aspect not touched on is isolation. Appliance control circuits are sometimes connected to potentially lethal voltages, internally. It's allowed when there is sufficient insulation such that the user can not come in direct electrical contact with it. That is where the opto-isolator is a good choice.

Sometimes a custom controller is not embedded in the appliance, the controlling device must then have access to extended wiring from the appliance, that might not share a common safety ground with the appliance. In some cases, that means "magic smoke" might come out.