Replacing or re-wiring your thermostat involves working with high voltage. Before doing any work, ensure breakers are turned off for the heating/cooling system, and the thermostat itself.
Do not assume the installer used the correct wires. Pre-installed furnaces and air conditioning units may be connected incorrectly. Ensure the correct wires are connected at the HVAC system and the thermostat. Improper wiring can damage or break either component.

Typical systems will have four wires coming from the wall:
There are two components being connected in standard thermostat wiring. The Heater and/or AC unit, and the thermostat. The HVAC unit will typically have a transformer that will convert the 240V or 480V power to a smaller voltage of 24V. The system is all powered by alternating current, so it will be 24VAC. This transformer connects to the Red wire and provides the power for the different components of the HVAC unit.
The other wires will simply divert the power to the specified component. Since most thermostats now use a circuit board, it is this board that is programmed to switch the power. If there are problems with any component of your system, this is a good place to start trouble shooting. A loose wire could prevent any component from working.

Above is the other common thermostat wiring schematic. It is similar to the previous, on the exception of two R cables. Here, the 24V power supply is “jumped” to the other R terminal. Jumping is simply adding a wire to connect the two terminals, so they share the 24V power. The Rh signifies a “h” for heat. Consequently, the Rc has a “c” for cooling which powers the cooling system.
If you are unsure of what to connect to your thermostat, check the owners manual. It will contain information on which terminals are used. They may be labeled different than Y, G, R, or W. Most digital thermostats will have more connectors for cooling systems with more options.
Larger heating and cooling systems will have more wires, depending on the other components of the unit. A good example of this is a air conditioning system with two stages of cold air. Two different wires power each stage. The second wire may be striped or another color. Again, make sure these wires have been connected to the HVAC unit properly. Do not assume they have been installed correctly. Here is a list of the other types of wires and what they do:
| Label | Color | Description |
|---|---|---|
| Rh | Red | 24VAC power to the heater |
| Rc | Red | 24VAC power to the cooling system |
| Y1 | Yellow | Relay for stage 1 cooling |
| Y2 | Blue | Relay for stage 2 cooling |
| W1 | White | Relay for stage 1 heating |
| W2 | Black | Relay for stage 2 heating |
| G | Green or Grey | Relay for fan |
| B | Brown | Relay for heat pump heating mode |
| O | Orange | Relay for heat pump cooling mode |
| E | Varies | Emergency heat pump relay |
| X | Varies | Emergency heat realy |
| T | Tan or Grey | Outdoor anticipator reset |
| L | Varies | Service Light |
Sources:
http://wiki.xtronics.com/index.php/Thermostat_signals_and_wiring
http://en.wikipedia.org/wiki/Voltage_converter
If you benefitted from this article, or know someone who would, please share below!