Parts We Miss: The Mains Transformer

About two decades ago there was a quiet revolution in electronics which went unnoticed by many, but which overturned a hundred years of accepted practice. You’d have noticed it if you had a mobile phone, the charger for your Nokia dumbphone around the year 2000 would have been a weighty device, while the one for your feature phone five years later would have been about the same size but relatively light as a feather. The electronics industry abandoned the mains transformer from their wall wart power supplies and other places in favour of the much lighter and efficient switch mode power supply. Small mains transformers which had been ubiquitous in electronics projects for many years, slowly followed suit.

Coils Of Wire, Doing Magic With Electrons

Inside and outside views of Jenny Lists's home made linear power supply from about 1990
This was a state of the art project for a future Hackaday scribe back in 1990.

A transformer works through transferring alternating electrical current into magnetic flux by means of a coil of wire, and then converting the flux back to electric current in a second coil. The flux is channeled through a ferromagnetic transformer core made of iron in the case of a mains transformer, and the ratio of input voltage to output voltage is the same as the turns ratio between the two. They provide a safe isolation between their two sides, and in the case of a mains transformer they often have a voltage regulating function as their core material is selected to saturate should the input voltage become too high. The efficiency of a transformer depends on a range of factors including its core material and the frequency of operation, with transformer size decreasing with frequency as efficiency increases.

When energy efficiency rules were introduced over recent decades they would signal the demise of the mains transformer, as the greater efficiency of a switch-mode supply became the easiest way to achieve the energy savings. In a sense the mains transformer never went away, as it morphed into the small ferrite-cored part running at a higher frequency in the switch-mode circuitry, but it’s fair to say that the iron-cored transformers of old are now a rare sight. Does this matter? It’s time to unpack some of the issues surrounding a small power supply.

Better DC, Or Just Resistance To Change?

The insides of a Cambridge Audio amplifier
Hi-Fi, the last holdout of the mains transformer. J. C. Barros from Portugal, CC BY 2.0

A traditional linear power supply was a very simple device: besides the transformer, you’d have a rectifier, a capacitor, and a three terminal regulator if it was a particularly fancy circuit. It could get a little warm, but what came out of it was as good a regulated DC as you could ask for. Switching power supplies on the other hand are more complex, particularly the older ones. There’s a rectifier and capacitor on the mains input, some switching transistors, that ferrite transformer followed by another rectifier, and keeping it all running a control IC with an optocoupler for mains isolation.

Switching power supplies can be very noisy, as anyone who’s used a shortwave radio near cheap consumer electronics will attest. This leads to an odd phenomenon among some engineers, the belief that all switching supplies are noisy — rather than just old or very cheaply built ones — which brings us to one of the last holdouts of the iron-cored mains transformer. Your TV, your computer, or your charger will have a switching power supply, but the chances are that if you own a high-end Hi-Fi amplifier it will have a large toroidal mains transformer. They may have gone from everywhere else, but audiophiles still like them. In that application we’re sure a large mains transofrmer will do a fine job, but here in 2024 we’d be inclined to dispute that an appropriately well-designed switcher wouldn’t be just as good, certainly with enough filtering downstream.

So the mains transformer is slowly shuffling off this mortal coil, and thus you are less likely to find one in your junk box than you once might have. Do you miss them? Probably not if all you want is a DC supply, but that’s not to say they don’t have other uses. If you’ve tried making a tube guitar amplifier you’ve probably been shocked at the price of audio transformers and pleased to find that an old wall wart can provide an alternative, for example. Do you still use mains transformers? Tell us below in the comments.

56 thoughts on “Parts We Miss: The Mains Transformer

  1. It’s gotten to the point where it’s surprising when you do come across something with a big, heavy mains transformer in it. For some reason pretty much all stereo/surround receivers seem to still have them, and lifting one is always fun because of the uneven weight distribution caused by the giant lump of iron.

    1. Mains Transformes have a lot of advantage for audio application’s:
      -They support being overloaded for a long time without long therm consequences.
      -They support huge over voltages without problem (SMPS don’t)
      -They can source power transients without problem.
      -they have a low output impedance and lower noise (better analog and transient characteristics)

      If you try to design a SMPS with all of this in mind you will end up with a 3 times more expensive power supply than the old transformer one.

  2. ” This leads to an odd phenomenon among some engineers, the belief that all switching supplies are noisy — rather than just old or very cheaply built ones”

    Actually, it is pretty much a given that a switching power supply is electrically noisy – expensive, cheap, new, or old.

    Take a portable (pocket) AM radio and tune it between stations. Carry it around your house and hold it near the power supply of your devices and appliances. You’ll hear interference from them all – except for the ones using old fashioned iron core transformers.

    While checking on how much interference one of my projects causes (https://josepheoff.github.io/posts/motorcontrol18) I found that I had to unplug a lot of devices in my workroom just to get a relatively clean comparison. Everything from the laptop to the monitors was spewing noise.

    1. And in audio applications, while the noise itself is pushed to inaudible ranges, it can too easily bleed out as ultrasound and burn your tweeters. It adds complexity to designs to filter it out.

      And then there’s the overload capacity of transformers. Since it’s a heavy hunk of copper and iron, it can take a beating and pump that bass all day long, whereas a switching power supply sized “just right” will start to cut off on you and eventually burn.

    2. That doesn’t say much, except that most consumer devices have noisy switch mode PSUs. Having had to get switch mode power supplies through RF emissions certification in one of my various works over the years, I can categorically say that if your SMPS generates that much noise it’s not a very good one.

  3. “Do you still use mains transformers? Tell us below in the comments.”

    Not often. I’m waiting for when I finish my 3d printer and CnC projects and get back to radio projects to see if I really need a linear supply or not. I think death of old age might be coming first though…

    But.. as long as we are asking questions…

    Does anyone use a hybrid supply? I’ve read about them but never seen one.

    It’s a switching supply outputting slightly higher than the desired output voltage fed into a linear supply. Still no big mains transformer since being DC that part of the linear supply is skipped. It’s just supposed to get you the clean output of a linear supply with most of the efficiency of a switching supply since the linear section only has to drop the voltage by a little bit.

    1. The cheap and plentiful adjustable power supplies available in multiple brands from your favorite online vendors are such hybrids. My $50 0-30V up-to-5A supply’s front-end switcher tracks the output voltage, feeding 2 volts more into the final MOSFET being a linear regulator.

      Frankly, that’s its only redeeming feature. It’s junk in every other respect. You get what you pay for, I suppose, but I can’t afford an HP or a Keithley. Or even a Rigol for that matter.

    2. Uh, just about everything uses these, partly because of the ubiquity of 5V USB as a power supply and the fact that most modern logic is 3.3 or 1.1v. If you look at your raspberry pi or random CNC controller or whatever, you’ll usually find a “ldo” or other linear regulator sitting between whatever the “input voltage” is (usually coming from a switcher these days) and the actual electronics.

  4. From a commercial perspective I agree, but from a hackers perspective…it all depends on where you reside. :-)

    Although not sold by the crate any more, here in South Africa you can still readily get cheapy small-VA transformers from the electronics shops (mostly comes from China), encapsulated PCB transformers (local), as well as custom-made toroid transformers (also local, with or without copper shielding), for not much more than the numeric cost of 20 years ago. A custom-wound, 300VA unshielded toroid will set you back around the equivalent of USD40-50.

    There is still very little that gets to the reliability of a transformer in an industrial environment…especially if your power generation network is running at 100% load capacity, 24/7…those mains spikes eat switchmode supply input DC capacitors for breakfast (with the resultant chain reaction destruction that follows), 3 times a day (loadshedding).

    As a radio amateur, I can build a 20-30A linear power supply for around the same cost as a cheap Chinese switchmode import. I’ll stick to transformers for as long as I can, thank you. Almost everything else needs either the DC caps replaced every 2-3 years, the whole power supply replaced completely, or dumped in the trash as U/S (well, going to my junk boxes actually). The resources on this planet are finite…I fail to see the benefit in efficiency if almost every switchmode supply (or devices with built-in switchmode), needs a replacement every few years. The justification for efficiency is negated the first time you replace the PSU.

    Just my personal opinion, but the move to switchmode was a serious de-evolution of engineering on this planet.

      1. “The move to switch mode allowed the long battery life of all your mobile devices. That’s not de-evolution.”

        No. Each car had a 13,8v cigarette plug which all mobile phones and ham/cb radios could use.
        No need for a switching-PSU.

        About mobile devices.
        These mobile devices de-evolve us, though.

        The iPhone type of smartphone was the worst that happened to society in the past few years.

        It also ruined the world wide web.
        Along with F-book. And social-media that aren’t really social.

        Merely in far away places like Japan, the 90s/early 2000s era web still exists.

        Tidy websites full of useful information, with clear borders and text-based hyperlinks to click onto.
        And no hamburger menu.

        Also: Before the iPhone, we already had futuristic mobile devices.

        We had PalmOS PDAs and Pocket PCs. Some with 2G/3G modem.
        There was the popular Nokia Communicator in 1996..

        Then there were Symbian devices, long before Android/iOS.
        They could go online no problem.

        We also had sub notebooks with keyboard to go online wherever we wanted.

        The Libretto 50CT was from the 90s, even and could run Win98SE.
        The most popular OS at the turn of the century!

        Even years before, in the Windows 3.1 days, we could go online easily with our notebooks.

        Some 386 era models had big linear PSUs still, but could still be carried in a nice laptop bag.
        No problem at all. Traveling was fun.

        The cellphones of the day had an internal modem and a serial cable or irDA.
        E-Mail on the go was absolutely no problem. Chatting via IRC or ICQ was possible, too. Way back in the 90s.

        Or let’s remember PDAs/Handheld PCs like the Ogo.

        We also cellphones with iMode and WAP browsers, for the mobile web.

        That was much more efficient and didn’t cause so much traffic.

        Much better “on the go” than this zombified www we now have to live with.

    1. This is a common misconception I see about switching power supplies, the input electrolytic capacitors in most switching power supplies almost never fail, with the only exception being either when they’re pushed too hard thermally, or if the power supply has some kind of active power factor correction, which is common in newer computer power supplies, and can wear out even the best quality electrolytics in a matter of years.

      The capacitors are most likely to wear out are the secondary side electrolytic capacitors, followed by any tiny electrolytic capacitors that may be dotted around the board. However, these capacitors can still hold up for years as long as you use good quality components, as I’ve seen switching power supplies last 20+ with good quality capacitors.

        1. Most power supplies I come across still use passive PFC, but that might be because I live in the US, who, at the moment, doesn’t seem to care about this, whereas the EU seems to care a lot more about this kind of stuff.

          I’ve seen this sentiment go back before active PFC was as commonplace as it is today, But as active PFC becomes more common, then eventually, the sentiment will become more true than false.

  5. Yes. I design and use both linear and switching power supplies.

    While my bench stock of off-the-shelf transformers is generally limited (and has been for the last 30 years), my bench stock of cores, wire, and related transformer hardware has only expanded over the years. The availability and capability of new linear power magnetic materials is astonishing. Designing with them can be difficult because electromagnetic circuit analysis and design techniques are not a prominent part of the general electronics education these days. Try designing a safe and useful custom power transformer sometime. You may find them more efficient and complex than you’ve heard.

    Transformers have always been one of the more costly and fussy components in a design. They can be breathtakingly complex and are usually one of the first or last components selected. Due to their weight and cost, optimization is usually worth the effort and most designers that use linear transformers either select a standard part that is already in a billion things and can be found cheap or spring for a custom one that makes the best use of the materials.

    Linear power transformers are still indispensable for uncountable situations. Power distribution, radio, metrology, and industrial control systems focus heavily on them. Closer to the workbench, most of the good, modern switching lab supplies still use linear stages after switching ones too.

    The idea that power transformers are somehow endangered, obsolete, inherently inefficient, or only used by superstitious audiophiles is absurd.

  6. I still have a decent pile of mains transformers, mostly things I’ve salvaged from discarded equipment. Some audio transformers too.

    I’ve seen very few mains transformers fail in service. Switching supplies die much more often.

    1. I’ve seen plenty of mains transformers fail in service (usually the embedded thermal fuse goes open) but, as you say, switchers fail far more often and I made a not bad at all thank you living from repairing them.

  7. Me: (aligning in v formation my new old stock of mains trafos)
    Also me: Autobots, Transform and Roll Out!!

    Nothing happens… maybe if I put them in series…

    Oh!- come on guys, have some fun!

  8. yes, I still use transformer power supplies, for all switches, the router and the weather station

    Our house is on a river’s high bank, electricity comes over open wires from 1915, and due to the nearby waterbody we have many lightnings striking during thunderstorms in summer or before snowstorms.

    I was early adopter for SPS, wanted to save electricity in all 24/7 wall warts.

    But… these died on me regularly during nearby thunderstorms or in two cases farted black magic smoke when the electricity returned after an outage.

  9. I used to live in a 60 unit apartment building. The switching noise was S9 or higher from 50 KHz to 175 MHz…
    Yes, I use linear supplies with big iron transformers wherever I can. Expensive but (nearly) bulletproof, and they don’t splatter noise all over the ham bands.

  10. I recently stumbled upon the curve tracer / octopus circuit. I’ve already scavenged a transformer from an old wall wart and have wide it up on a breadboard, but I’m gearing up to turn it into a usable tool soon.

  11. Variacs (variable autotransformers) are a kind that’s great to have. Sure, sometimes you need isolation, but a lot of times you really don’t. Adjusting the sine voltage makes them far better dimmers/speed controllers than triacs, even if a 1.4kW variac can cost $50 instead of $20 and is bigger and heavier than the equivalent semiconductor device. You can also boost the voltage an extra 16 percent, if what you’re using can run at higher power than normal for a limited time. Since they’re so simple, if you want to use them differently and know what you’re doing, you don’t need to do much. Sometimes large ones are used to balance a split-phase off-grid system. You could also use one to adapt other voltages of the right frequency.

    Constant voltage transformers are a kind that uses more complex magnetics than simple voltage transformation. They are made to saturate in such a way that for most loads in their rating, any input voltage close enough to the nominal mains voltage will produce approximately a constant output voltage. This can also help soak up momentary surges or drops. They can also, provided temperature is kept in check, produce a constant AC current output when you attach a load that would otherwise draw greater than their power rating. The voltage will lower to bring this about when overloaded, and they can tolerate this condition for an extended period. Constant-current adjustment on older welders used to use transformers and movable shunts.

    For signals and higher frequency power use, modern core materials can be very impressive, to the point that it’s a bit unfortunate if you use a 60hz mains transformer for fancy audio purposes, even if it can certainly be done. That’s not even getting into magnetic amplifiers…

  12. The reason because transformers are still used on class AB and B audio amplifier, and push-pull A class amplifiers, is that they work with unregulated power supplies, basically the feedback makes the amplifier their own power supply. You can use an LM317 as an audio amplifier.

    1. I work with med tech at a large hospital. A lot of modern devices still uses a mains transformer. Probably due to the difficulty of designing a smps with low interference when you cannot properly filter the mains input. The filter would cause too much leakage current.

      Personally I like them. They still have their use. Maybe not in a phone charger, but in a lot of other places. Also, a big toroid can actually be quite efficient. The losses come with rectifying and regulating the output.

      1. I think it’s probably because they offer better isolation from mains, and thus prevent shock hazards to patients and staff. Probably important in healthcare settings. ;-)

        I also recall “isolated grounds” being a thing in hospitals, but I’ve no direct experience with them, so I don’t know whether that’d factor into it.

  13. > Do you still use mains transformers? Tell us below in the comments.

    Sometimes. Usually I use them to go to lower voltage (with a bridge rectifier and caps) for input to a low voltage switcher. Occasionally, I need AC in a project and that pretty much requires a mains transformer.

    The switch mode wall warts can be pissy about driving inductive loads. While I was messing around with input filter designs for low voltage switchers, I found that it was necessary to have a mostly capacitive load on the switcher type wall warts for them to start up reliably.

  14. One underrated advantage of traditional transformers is their longevity.
    They can potentially work for hundreds of years without degradation of performance.

    Most SMPS designs usually have their lifetime limited by capacitors’ disease.

  15. Lets not forget that the electricity supply most of us are tapped into reading hackaday right now, (the one coming into your house/apartments’ electricity meter) is almost certainly supplied by a large iron cored wire wound transformer somewhere nearby. They may be technological dinosaurs, their components and designs have changed litte in over 100 years, but they are still made currently and in daily use all over the world.

  16. I dislike them intensely. I bought an early commercial switcher with 5V and 12V out to replace the ludicrously heavy supply in a large OSI 6502 system in about 1983 and it is still running. I’m not sure the giant electrolytics in the old one would still be working, but I know the medical bills are lower. Nobody needs a surprise hernia.

    I have half a dozen old systems that I do not take to shows or gatherings because of the weight. IMSAI 8080, Challenger II, Rockwell Design Center, etc. The weight is probably doubled or more by the copper and iron in the transformer. I occasional think I should swap to switchers in these and save the original power system so some future owner can help out a poor surgeon.

    The silly design of S100 Bus systems looses a lot of PCB real estate by putting regulation on each board and the PSU in the ISAI puts out +-16 and and a +7 is rated for 28A. A typical HP server supply is rated at 5V and 200A. It would run pretty quiet at the 28A max. I wonder how far it can be tweaked for the 7V? Anyway, companies like Meanwell have lots of options and they are very affordable.

    Lately I have been buying some nice Meanwell DIN rail 5V and 12V and 24V that are very small and light and setting up some lab/shop stuff.

  17. You bet i do use a linear PS.
    I had a lightweight switching once, and the noise it put in all my circuits was jut awful, whatever filters you try to put in between. I check inside, and it was kinda state of the art with proper filters : at input and output, common mode / differential, and (afaics) of really decent quality.
    I switched (aha..) to a linear one, and it’s a life changing.
    I guess I could still use a SMPS for stuff requiring some beefy power, like motors, lights and such. But for my use case (low voltage analog, mcu, ..), there’s no way other than a linear PS with a heavy (toroidal in my case) transformer.

  18. Microwave ovens have massive transformers. Could a SMPS ever replace them with a tiny transformer ? My gut says they would arc like crazy and providing enough insulation would negate any advantage.

    1. Panasonic is using switch mode power supplies and their microwaves for the last several years. Look for the term inverter on the outside of the microwave somewhere. They do not seem to have an arguing problem and last.

  19. “(2) this device must accept any interference received, including interference that may cause undesired operation”. A lot of amateur equipment (especially ham) was designed during a less noisy time when you could get away with designs that have zero consideration for EMI, and that is no reason to halt progress. SMPS supplies today are in general very good, but the switching component is easy to mess up, and a lot of home labs really can’t measure the noise properly.
    In my opinion, if you use through hole components and deadbug construction, you really have brought the noise issues upon yourself.

  20. I do use an old main transformer made in 1964 to power some 110/120V devices from my european 230V main. Some of these devices also have a main transformer inside, some other uses SMPS (not 230V compatible one, as the exploded varistor remind me last time i accidentaly plugged it directly to 230V, with luckily no other damage).

  21. I work with med tech at a large hospital. A lot of modern devices still uses a mains transformer. Probably due to the difficulty of designing a smps with low interference when you cannot properly filter the mains input. The filter would cause too much leakage current.

    Personally I like them. They still have their use. Maybe not in a phone charger, but in a lot of other places. Also, a big toroid can actually be quite efficient. The losses come with rectifying and regulating the output.

  22. By the time I was born in 1951 my dad was running a local radio station. Those were the days when you bought sound by the pound. And that philosophy didn’t change much for the succeeding five decades or so. When my own vagabond radio career wound down about 15 years ago I took the DIY audiophool route. Massive toroids and capacitors for MOSFET amps. But when I got into active speaker systems requiring a separate channel of amplication for each driver SPACE became a problem. Right now, eight channels are in use, and I want at least four more for a distributed subwoofer system.
    Enter Hypex class D modules, powered by switch mode supplies. Massive power, in teeny weeny packages! As far as my ears are concerned though, they just don’t have the refinement of my homemade class A/B amps when played on full-size speakers. But, for subwoofers, the level of class D I’m using is more than adequate.
    Higher up the class D/switchmode chain there are phenomenal products that CAN go toe-to-toe with the toroid boys. Unfortunately, the prices from most of the traditional makers remain in the stratosphere. And even more unfortunate for western economies, it’s the Chinese who are bringing much of this cutting-edge tech to market at beer budget prices. Lots of good things being said about WiiM. Aiyima, Dayton Audio, Fosi Audio, and others.

  23. Absolutely miss them. I’ve had to replace one for an audio setup and another for a set of Christmas tree LEDs (that used a big 24v AC transformer).

    Tangentially a few years back when there was an issue with generic apple iPhone chargers (and apples replacement program after someone died while on the phone while it was charging) there was some “expert” on the national news that said the heavier it is the better the quality and if it was light, bin it. I remember thinking at the time this guy was probably an expert on the 90s as the knock off chargers were almost the same weight as the genuine ones at the time.

  24. When it comes to my lab bench, making prototypes, or one-off/personal projects, I go with traditional power transformers, unless there’s a compelling weight or efficiency reason not to. Simply put, iron-core mains power transformers have been more reliable, and I only need to filter 60 Hz instead of somewhere in the 10s of kHz and harmonics.

    Charging my cell phone, or powering the vast majority of modern consumer electronics, though? Nah. Almost all of it comes with an SMPS, or has its own built-in, anyway. It doesn’t make sense in modern computer systems either, since PSUs are standardized and are pretty efficient these days.

    1. +1

      You got a big fat kudos here! 😎

      What people often oversee is that prototypes are not necessarily of low quality.

      Rather the contrary, in practice.
      A prototype is the kind of product that hasn’t undergone a cost-saving measure procedure yet.

      It’s priority is to be fully functional and accurate. For evaluation purposes.

      That’s why universities used to work with prototype models.
      They were made of high quality parts and didn’t care about saving money.

      Stuff made for military used to be very rugged, too.
      Because money was being secondary, this was feasible.

  25. About the first “creation” (picture).. Oh, my child! What have you done?! 😭
    The transformer looks good, but the rest.. No, just no.

    That’s not state of the art, never was.
    Haven’t you read popular electronics or 73s magazine? They explain things.

    Kid, by 1990, we had something called “protective earth” and fuses. For years.
    Why didn’t you use a three pin plug, with protective earth?
    If you did, why do you have to hide the power plug?

    Second, your soldering skills are fine, but please don’t let PCBs float freely inside a metal chassis.
    Use electric tape, at least, and wrap them up!
    The toggle switch shouldn’t be blank, either. Give it a hat, at least.

    Jesus, my heart. 💔 Please have mercy on an old 🧓

    Nostalgia is fine and such, but this looks like the ingenious “work” of a CB radio operator broke lose.

    Or an old “I know everything better than you” / “I’ve always done it that way!” kind of radio amateur who had less years ahead than behind.

    I know these people.
    They don’t believe that electricity is harmful.

    Anyway, I’m so grateful for RCDs being standard these days!
    They saved lifes of innocent neighbors, pets and families who had such a hacker next door.

    PS: Please don’t get me wrong. That PSU was okay, electrically.
    But the safety measures and the chassis..
    I don’t know. My dad (a ham, but a wise specimen) wouldn’t ever have allowed me to plug this thing in.

    Again, it’s not the circuit or the skills. It’s just the build.
    It’s too.. raw and unpolished. Needed proper fix up and more investment.

    Vy73/55

  26. I wish I had some big transformers or a varac. Their useful for messing with nixie tubes or just old tubes in general. Though most tubes draw so little current that I can handle most of my needs with a decent smps since nixies/decatrons etc all work fine with DC voltage (I honestly can’t remember if their designed for AC or not. When I do projects with them I’ve always used HV DC).

    Smps can be a nuisance if your also into ham radio or you can hear high pitched noises (both for me). I got a lamp recently and kept searching my room for whatever was causing the annoying buzzing noise and finnally just started yanking wall warts. It was the new lamps wall wart so I guess I’ll have to see if I can find a nicer built one to replace it so the buzzing stops (it buzzes even when the light is off).

    1. I’m mostly just happy that Tube orientated Transformers are still being made. Hammond mfg. in particular is the most well known and popular choice for anyone making a Tube Amplifier in this day and age. Though there are also Toroidal options to be found by those like Antek.

  27. I do low volume production on high-tech laboratory equipment and we still use Toroidal Mains transformers. Within those typical semi-compact solid aluminum housings one use for Control systems they are more convenient to work with to get a whole slew of rails, than using multiple SMPS Modules or having to create/outsource a custom module.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.