Pellagra is a systemic disease caused by a severe deficiency of niacin (vitamin B3). It affects the whole body and can eventually lead to death. Primary pellagra is caused by a lack of niacin in your diet. It usually occurs in poor and food-limited populations