The Rambam writes (Ma’achalot Asurot 14):
“One is not liable for partaking of any of the prohibited foods unless one partakes of them in a manner in which one derives satisfaction with the exception of a mixture of meat and milk and mixed species grown in a vineyard. [The rationale is that with regard to these prohibitions, the Torah] does not use the term “eating,”but instead conveys the prohibition against partaking of them in other terms. [With regard to meat and milk, it uses] the term “cooking” and [with regard to mixed species grown in a vineyard, it uses the term] “become hallowed.” [This implies] that they are forbidden even when one does not derive satisfaction.”
“What is implied? When one liquefied fat and swallowed it when it was so hot that his throat was burned from it, he eat raw fat, mixed bitter substances like gall or wormwood into wine or into a pot [where meat from] a nevelah [is cooking] and he partook of it while they were bitter, or he ate a forbidden foot after it became decayed, spoiled, and unfit for human consumption, he is not liable. If, by contrast, he mixed a bitter substance into a a pot [where meat and milk are cooking] or into wine from a vineyard where mixed species are growing and partook of it, he is liable.”
Maran rules (Yoreh De’ah 155:3):
“Regarding other prohibitions (aside from meat and milk and forbidden vine mixtures) we heal people with them in life-threatening situations, even when consumed normally. In non-life threatening situations: when consumed normally – it is forbidden; when consumed irregularly – it is permitted.”
My Rabbi and Teacher, HaRav Yaaov Peretz shlit”a notes:
“Medical pills and capsules for Pesach that we suspect may contain Chametz and are unfit for usual human consumption – are permitted.”
There are those who are lenient and say that even for a healthy person, irregular consumption is completely permitted (Shach, Mordechai, Agudah in the name of the Ra’aviah, Mishne LaMelech, and Tosafot). But many Poskim say that a healthy person should be stringent, but an unwell person who is not in a life-threatening situation may be lenient. (Shoshanat HaAmakim – the Peri Megadim).
Regarding medications, I believe that everyone may ideally act permissively – assuming they are swallowed. Regarding non-vital supplements and vitamins, both those who wish to act leniently, and those who wish to act stringently – have on whom to rely.
Who should read this? Please see here: