A newly purchased baking pan is full of promise. But the smooth gleam of unused metal doesn't last for long. Eventually you'll end up with burnt-on stains, permanent grease spots, and, if you're not careful, patches of rust.

You may be most familiar with rust developing on a cast-iron skillet, but there's plenty of metal cookware that can take on a layer of orange. Bakeware in particular is a common culprit—and the cause is typically a combination of improper maintenance and general wear and tear.

Rust on your cupcakes is definitely not appetizing, but is it also unsafe? Is it ever okay to bake with rusty pans? We consulted Dr. Bryan Quoc Le, food scientist and author of 150 Food Science Questions Answered, to unpack everything you need to know about rusty bakeware.

How Do Baking Pans Develop Rust?

rustic shabby pie panpinterest
zkruger//Getty Images

Depending on the type of baking pan you have in your kitchen, the material of your product will vary. "Most bakeware is coated in a thin film of polymer, enamel, or ceramic to prevent the process of rusting in the metal below," Le says. The metal, typically aluminum or stainless steel, can be rust resistant, but not entirely rustproof.

Chips and scratches in the exterior coating are bound to happen with regular use. These chips expose the metal inside to elements that will increase the rate of rusting. Specifically, metal will interact with "air, water, salt, and acid," says Le, "all of which can destroy the microscopic coating that naturally protects the surface of the metal."

Is It Safe To Bake With Rusty Pans?

soft batch cream cheese chocolate chip cookiespinterest
Candice Bell//Getty Images

It's not particularly safe, but the hazards posed by rusty pans vary in terms of severity. Rust is not a food-safe material and shouldn't be ingested, but you may not be exposed to it depending on what you're baking. If the rust is minimal and you're using parchment paper or baking cups to line your baked goods, you can theoretically use the pan without exposing yourself to rust.

It gets more complicated when your food is directly touching the metal—especially if there are acidic ingredients present. "If highly acidic foods touch rusty bakeware, primarily foods that contain citrus ingredients or citric acid, they can dissolve the rust and rapidly increase the heavy metal content of the food," Le says. "This will result in higher ingestion of heavy metals that can lead to long-term metal poisoning."

Regardless of the health-related risks, there are other consequences of rust that will affect your bakeware. Layers of rust will make the surface of your baking pans less even, which makes them work less effectively. "Rust itself is not quite as heat-conductive as pure metal, so there will be areas in the bakeware that aren't quite as hot as others during the baking process," Le adds.

In addition, the presence of rust typically indicates that the rust-resistant coating has chipped or scratched—which means those particles may end up in your food. That's especially true when it comes to bakeware with nonstick coating. And on top of that, the degradation of the coating will compromise the nonstick power of the product anyway.

What Should You Do If Your Baking Pans Develop Rust?

piles of pans and containers stacked in a row in some kitchen cabinets in a restaurant kitchen, front close up viewpinterest
aire images//Getty Images

If you notice that your baking pans are developing rust, the best decision would be to replace them with new ones. "The risk far outweighs the benefit of trying to recover the baking pan," Le says.

Le adds that you could, in theory, rely on a phosphoric acid-based cleaner to remove the rust from your pan. But the scratches and chips that facilitated the rust development are still there—so you should still probably buy a new baking pan anyway.