If you're allergic to shellfish, a CT scan with contrast could precipitate a bad allergic reaction due to the cntrast solution....
Actually, the connection between seafood allergies and IV contrast allergy (as well as allergies other types of iodinated medical products, such as surgical preps) is a myth. It was based on a 1975 article (Shehadi, 1975) that found a correlation between patients with atopic reactions to foods (not just seafood) and the tendency to have allergic-type reactions to IV contrast dyes. IV contrast dyes cause reactions because they are potent stimulators of the release of histamine and mast cells. Patients with a tendency to atopy are likely to have more reactive mast cells.
Frequently people believe that a seafood or IV contrast dye reaction is an "allergy to iodine". An allergy to iodine would be fatal, as iodine is ubiquitous in the body. Unfortunately, the myth is also pervasive in medical practice, as pre-op nurses and even radiology personnel frequently have a protocol of asking patients if they are allergic to seafood, and if so, avoid iodinated contrast dyes. It might make sense if they asked about a allergies to any food, or a history of frequent atopic reactions in general, but not specifically seafood.
Here a couple of links to read about the mythology of the seafood allergy/IV contract connection:
MYTH OR REALITY: ARE SHELLFISH ALLERGIES RELATED TO CONTRAST REACTIONS?
Intravenous Radiocontrast Media: A Review of Allergic Reactions
In any case, MRI contrast is not the same as CT contrast. It's a substance called gadolinium that works by temporarily changing the magnetic properties of tissues to enhance imaging under MRI (to put it very simplistically). There are reports of rare adverse reactions in patients with pre-existing kidney failure, which can cause retention of gadolinium in the body, possibly resulting in a syndrome called
nephrogenic systemic fibrosis. True allergic (anaphylactic) reactions to gadolinium are very rare, according to
this article, occurring in 1/10,000 patients who receive gadolinium.