The figures from the country's health boards have prompted outrage from charities and politicians, who have insisted there are no excuses for fatalities related to a condition branded "Victorian" and "Third World".
The total number of deaths is likely to be higher, as two health authorities – NHS Ayrshire and Arran and NHS Borders – claimed they could not provide details in response to a freedom of information request.
Age Scotland has called for greater emphasis to be placed on detecting malnutrition in older people before it reaches a critical stage, after it emerged 359 of the deaths related to patients aged over 65.
A spokesman for the charity said: "Many older people enter hospital and other care settings in malnourished states, for a variety of reasons. Screening on admission is paramount so ward staff are aware a patient has difficulties. We would also like to see more being done outside the hospital by health visitors, other care personnel and families to ensure incidences of malnourished older people entering hospital are reduced."
In total, malnutrition was listed as the primary cause of death of at least 40 people, 27 of whom were pensioners. It contributed to a further 447 deaths, with 332 relating to cases involving the elderly.
Some experts have claimed malnutrition could be affecting millions of people in the UK every year. Characterised by unplanned and often dramatic weight loss, it can also lead to a weakened immune system.
Scotland's largest health board, NHS Greater Glasgow and Clyde, recorded the highest number of deaths in which malnutrition was a factor. The condition directly killed 23 people in the region, including 16 pensioners. Doctors said it contributed to a further 120 deaths, including those of 69 people aged over 65.
Opposition parties expressed shock at the situation. Scottish Labour health spokeswoman Jackie Baillie said: "When we hear of deaths from lack of food we think of the Third World – not our own doorstep."
Jackson Carlaw, health spokesman for the Scottish Conservatives, added: "Nobody in modern Scotland should lose their life because of malnutrition. People associate such cause with Victorian times."
A Scottish Government spokes- woman said: "We have com-mitted £1.75 million to introduce malnutrition screening, nutrition champions in every NHS board and protected meal times to help patients who need help with eating."