Norway was an important source of iron ore, but there were two more important reasons for the German invasion. Primary was the strategic location of the country, and if the British had seized Norway Germany would have been outflanked to the north before the war was well underway. This not only would have been disastrous in terms of losing control of the northern seas and the exit from the Baltic, but would have left the British in control of a direst route to Finland and Russia. The primary reason Hitler invaded Norway was to forestall this, which was indeed the plan of the British.
Although those two reasons were important, there was a third very important reason. That was the company Norsk Hydro, the world's only commercial source of deuterium, known as "heavy water." This is essentially water with an extra hydrogen atom, and which was used as the moderating agent to control the reaction of uranium in atomic research. The method of creating an atomic bomb which was being pursued by German scientists depended on heavy water.
German, Russian and British scientists had been working on an atomic bomb since before the First World War. Norsk Hydro's production was immensely increased during the war, but the shipment of large quantities was stopped by various means. There were several attempts at sabotage, some successful, and one major commando raid on the plant. It could not be successfully destroyed by bombing because of its position inside a steep valley at the base of a mountain. In February of 1943 the facility was heavily though temporarily damaged by a raid carried out by Norwegian and British commandos, some of whom had been living on the snow covered mountains for months. On 20 Feb., 1944, the Germans shipped a large quantity of deuterium in barrels on a ferry down Lake Tinnsjo; the ferry was sunk by a time bomb set by Knut Haukelid, a Norwegian commando. This was essentially the end of Germany's attempt to create an atomic bomb, although it was actually beyond their capabilities. They simply did not have the money or manpower available to carry out the massive industrial effort required at the time.