In view of the looming energy crisis facing our planet, attention increasingly focuses on materials potentially useful as a basis for energy saving technologies. The discovery of giant magnetocaloric (GMC) compounds - materials that exhibit especially large changes in temperature as the externally applied magnetic field is varied - is one such compound 1. These materials have potential for use in solid state cooling technology as a viable alternative to existing gas based refrigeration technologies that use choro-fluoro - and hydro-fluoro-carbon chemicals known to have a severe detrimental effect on human health and environment 2,3. Examples of GMC compounds include Gd5(SiGe)4 4, MnFeP1-xAsx 5 and Ni-Mn-Ga shape memory alloy based compounds 6-8. Here we explain how the properties of one of these compounds (Ni2MnGa) can be tuned as a function of temperature by adding dopants. By altering the free energy such that the structural and magnetic transitions coincide, a GMC compound that operates at just the right temperature for human requirements can be obtained 9. We show how Cu, substituted for Mn, pulls the magnetic transition downwards in temperature and also, counterintuitively, increases the delocalization of the Mn magnetism. At the same time, this reinforces the Ni-Ga chemical bond, raising the temperature of the martensite-austenite transition. At 25percent doping, the two transitions coincide at 317 K.