I guess the title says it all. How big of an electromagnet would you need to generate a magnetic field the same as Earth's? Like, what kind of amperes are we talking here? (Assuming a hypothetical superconducting magnet, of course.)
You are in luck, since Osamu Motojima and Nagato Yanagi have already calculated it for you in their report Feasibility of Artificial Geomagnetic Field Generation by a Superconducting Ring Network. They conclude that producing 10% of the current field is feasible using "12 latitudinal high-temperature superconducting rings, each carrying 6.4 MA current with a modest 1 GW of power requirement".
(The motivation for the report is the concern about the consequences of Earth losing its field during a geomagnetic reversal, but it doesn't look like those are particularly bad.)