RepairPal estimates the cost of replacing an air conditioner or heat pump compressor to be between approximately $750 to a bit over $1,000, as of 2015. Compressors form the heart of air conditioners and heat pumps, so replacements can be expensive.
Both air conditioners and heat pumps rely on temperature increasing with pressure. As a refrigerant is compressed, it heats up. This heat can be used to warm air in the case of a heat pump in heating mode, or the refrigerant can be decompressed after its heat has been dissipated outdoors, as is done with air conditioners and heat pumps in cooling mode. Replacing compressors requires disassembling the unit and reattaching a number of components.