Formulas are derived for computing the flux linkage of windings modelled in finite element computations by regions with given current density. It is shown that, if there is a single winding only in the finite element model, its flux linkage is the ratio of the sum of the magnetic energy and co-energy to the winding current. Alternatively, if there are other current-carrying conductors present in the problem region, the sum of the energy and co-energy has to be supplemented by a surface integral of the product of the magnetic scalar potential and the flux density over a surface enclosing the winding. Finally, these formulas valid for current-carrying coils not embedded in one another are generalised to coils carrying no current and/or surrounding other coils with non-zero current. The results do not involve the magnetic vector potential and are hence useful if the finite element solution is in terms of a magnetic scalar potential. The relationships obtained are valid even if the problem is non-linear.