This calculator tool supports a Boost Converter Flyback setup which means now the code considers:
Corrected turns ratio and primary voltage logic since the flyback works by storing energy during "ON" time and transferring to secondary during "OFF" time.
Flyback boost topology where output voltage is higher than input.
An accurate duty cycle formula for isolated flyback (especially in DCM).

Flyback Transformer Estimator
Calculates approximate primary turns, secondary turns, turns ratio, and reflected voltage for a flyback transformer.
Results
Duty Cycle: 0 %
Primary Turns (Np): 0
Turns Ratio (Ns/Np): 0
Secondary Turns (Ns): 0
Reflected Voltage: 0 V
How to Use This Boost Flyback Calculator
This calculator gives you a quick estimate of the primary turns, secondary turns, transformer turns ratio, and reflected voltage for a flyback transformer.
To use the calculator, just enter the following parameters:
Input Voltage (Vin): The DC supply voltage applied to the primary winding.
Output Voltage (Vout): The required DC output voltage.
Switching Frequency: The operating frequency of the flyback converter in kHz.
Core Cross-Section Area (Ae): The effective magnetic cross-sectional area of the ferrite core in mm².
Maximum Flux Density (Bmax): The maximum allowable flux density of the ferrite core in millitesla (mT). For most ferrite cores, values between 180 mT and 250 mT are commonly used.
Target Duty Cycle: The desired maximum duty cycle of the converter. A value between 40% and 50% is typically selected for flyback designs.
After entering these values, click the Calculate button. The calculator will show you the following figures:
- Primary Turns (Np)
- Secondary Turns (Ns)
- Turns Ratio (Ns/Np)
- Reflected Voltage
- Duty Cycle
The results provide a useful starting point for boost type flyback transformer design and verification.
Practical Calculation Example
Let us Assume we have the following specifications:
Vin = 12 V
Vout = 220 V
Frequency = 50 kHz
Ae = 125 mm²
Bmax = 200 mT
Duty Cycle = 45%Step 1: Convert Units
Ae = 125 × 10⁻⁶ m²
Bmax = 200 × 10⁻³ T
= 0.2 T
Frequency = 50 × 1000
= 50000 Hz
Duty = 45 / 100
= 0.45Step 2: Calculate Primary Turns
Formula:
Np = (Vin × Duty) / (Bmax × Ae × Frequency)Substituting the values:
Np = (12 × 0.45) / (0.2 × 125×10⁻⁶ × 50000)
Np = 5.4 / 1.25
Np = 4.32 turnsThe calculator rounds this to:
Np = 4 turnsStep 3: Calculate Turns Ratio
Formula:
Turns Ratio =
((Vout + Vdiode) × (1 − Duty))
/
(Vin × Duty)Assuming:
Vdiode = 0.7 VThen:
Turns Ratio =
((220 + 0.7) × 0.55)
/
(12 × 0.45)
Turns Ratio =
121.385
/
5.4
Turns Ratio = 22.48Step 4: Calculate Secondary Turns
Formula:
Ns = Np × Turns RatioTherefore:
Ns = 4 × 22.48
Ns = 89.9Rounded:
Ns = 90 turnsStep 5: Calculate Reflected Voltage
Formula:
Reflected Voltage =
(Vout + Vdiode)
/
Turns RatioSubstituting the values:
Reflected Voltage =
220.7 / 22.48
= 9.82 VSo Final Result Gives:
Duty Cycle = 45 %
Primary Turns = 4 turns
Turns Ratio = 22.48
Secondary Turns = 90 turns
Reflected Voltage = 9.82 V

Comments
It’d be better if core path length and cross sectional area were computed from geometry, especially for toroids with rectangular cross sections and linear inductors (open/antenna-type and the 3 common shielded types (round-shield, 4-corner-shield and 2-corner-shield) in open-top and round-covered). Other types include I-shape, Bobbin, Drum, and shielded-toroid.
The calculator gives a good reasonable calculation for all the average users, I did not want to over complicate the calculations unnecessarily. If you are interested for extreme accuracy you can use formulas and calculate it manually.
Interesting as is your program, I think in the real world, we need to take account of winding self-capacitance. Entry-level as efforts have been, the most I have got is around 100V from a 12V input. Where migh tI be going wrong? Thanks! Cheers!
Hi, Thanks for your feedback. I think the output voltage mainly depends on the turns ratio. If you do the turns ratio correctly as per the calculations, then you can achieve any desired high voltage you are looking for.
Yes self-capacitance must be considered and can be minimized by using good quality Litz type wire…