A relativistically invariant expression for the magnetic and electric helicities of free electromagnetic field through the currents, which created those field, are derived. It is demonstrated that the both helicities are conserved quantities of radiative fields and are equal to each other. Moreover the conservation of the helicity in radiative fields means that in such fields electric and magnetic fields are always orthogonal to each other. Proceeding to the quantum theory, it is shown that the corresponding quantum helicity field operator is equal to the sum of projections of spin moments of all photons onto their momentums. Finally, as an example, the expressions for the total helicity, number of photons and the total spin momentum of the field of a dipole electromagnetic pulse are obtained and discussed.