How strong is Earths magnetic field in space?
At what distance? The Earth's magnetic field is roughly modeled as a tilted dipole (i.e., the magnetization axis is tilted with respect to the spin axis of rotation). The magnitude at the magnetic equator is given by the approximation:
$$
\lvert \mathbf{B} \rvert \left( r \right) \approx B_{o} \left( \frac{R_{E}}{r} \right)^{3} \tag{1}
$$
where $R_{E}$ is the Earth's radius, $B_{o}$ is roughly 31,200 nT (i.e., the average field magnitude at the Earth's surface near the magnetic equator), and $r$ is the distance from the center of Earth.
As you can see, by the time you reach ~4 $R_{E}$ the magnetic field has dropped to ~490 nT.
would it be strong enough to attract any sort of magnets back to the Earth?
I doubt one could actually create a scenario to test this as all things in space are orbiting at several km/s. Some spacecraft do use the Earth's magnetic field for orientation/attitude control, but generally these just cause small rotations not radial forces or effective drag forces.
or repel it away if it's facing the similar magnetic pole?
I highly doubt this.
Does that mean a neodymium magnet with the strength of 1.4 tesla and hypothetically the same size of the Earth can protect itself far much better from Solar Wind?
If we had a stronger field and the source region was as large as the Earth, then yes. If you used something the size of a small refrigerator magnet then no. You could see this by changing (in Equation 1 above) $R_{E} \rightarrow r_{o} \sim 1 cm$ and $B_{o} \rightarrow b_{o} \sim 1 T$. The size of the source shrunk by ~8 orders of magnitude while the strength of the field only increased by ~5-6.
The Earth protects us from the solar wind because those particles are charged, thus they respond to a magnetic field. The Earth's magnetosphere also creates a bow shock upstream of the Earth, which provides additional protection since it slows down any inflowing particles and deflects them (due to gradients in the magnetic field).
I wrote some more details on the effects of the solar wind at https://physics.stackexchange.com/a/214509/59023.
First, an electron has both an electric charge -e and an intrinsic magnetic dipole moment N-S, μ.
Static electricity in the needle means that you rearrange the charges in the needle and you spatially split them in negative region (one end of the needle) and positive (other end of the needle). Negative region is the region which has an excess of free electrons where positive region is the region which has a lack in the number of electrons. This charge imbalance causes the electrostatic charge and field of the needle when rubbing it with a cloth.
However in this kind of charge the magnetic moments of the electrons are randomly scattered in any direction therefore there is no magnetization of the needle thus it CANNOT SENSE and respond to the magnetic field of the Earth.
Magnetostatics are different. Charges (i.e. electrons) are evenly distributed inside the matter of the metal needle. If you can find a way assuming the needle material is ferromagnetic to re-orient all magnetic moments of the unpaired electrons to align to the same direction then you will magnetize the needle and it will sense the magnetic field of the Earth and needle will respond by aligning to the magnetic field of the Earth!
See below illustration of the difference between electrostatically charged matter and magnetically dipole charged matter (i.e. magnetized):
Green arrows represent the magnetic moments N-S direction of the electrons.
It all depends on the material if it is magnetizable or electrostatic chargeable? There are materials that respond both to magnetic and electrostatic charging but eletrostatically charging a material will not make it magnetic and magnetizing it will not make it electrostatic.
Note: Even, when uniformly rubbing the needle with a cloth so that you end up with a uniformly electrostatically charged needle (i.e. the whole needle surface lacks in electrons or has an excess of electrons relative to other material objects), it will still have its charges' magnetic moments randomly oriented and therefore you cannot achieve magnetization of the needle by triboelectric effect. Electrostatic charging is about spatially transferring whole charges from one place to the other. Magnetostatic charging is about turning the charge's magnetic moments so that they face all to the same direction. It's two different things which each requires a different procedure to be accomplished assuming the specific material's atomic structure allows it.
Update 22 Nov 2021:
Although the above answer is describing the general case farther investigation revealed this article I cannot dismiss lightly since in almost every rule there are exceptions and we must be open minded:
Survival Gear: How To Make A Compass
It says: "you can magnetize a needle by rubbing it against your hair, some animal fur, or silk. Carefully hold the sharp point of the needle and rub just the eye of the needle 50 to 100 times against the hair, fur, or silk."
In first glance this may seem ridiculous but there is possibility to both electrically charge in this case the needle and also magnetize it!
This is because it says to only rub the eye, the very tip of the needle. It is possible in such as small volume (less than a few microns cross-section) the electrostatically accumulated charges in there to end up also more or less with aligned magnetic moments in the same direction. Therefore aligned magnetic domains are formed at the very tip of the needle that would act as a magnet.
Only an actual experiment can tell with the needle seeking the Earth's magnetic south pole (i.e. located close to the Geographic North pole).
I expect this magnetization effect to be very small, if any at all, but a needle floating on water, could work.
Update 26 Nov 2021:
I did an experiment linked on the comments below (please read also my related comments below addressed to @Ed Flea, to avoid any misunderstandings). Nothing conclusive unless repeated many times and replicated also by others, although it seems at first glance a positive result.
Update 28 Nov 2021:
Okay, I have repeated this experiment many times now and my results show conclusively that you CANNOT magnetize the eye of a needle by static electricity (i.e. triboelectric effect) as some of these survival guides magazines claim.
The first experiment run I've got a positive result must have been a fluke, somehow accidentally the needle must have been magnetized. I bought some new needles and repeated the experiment 10 times, always with the same result. No magnetization of the needle.
Conclusion: You cannot magnetize a needle by static electricity.
Best Answer
I'm glad you posed your friend's original question of "How come a compass usually points North instead of at the nearest fridge magnet?" because that's a more straightforward and apt question than the question derived from it. The Earth's magnetic field at the surface of the Earth has an average magnitude of about 0.5 Gauss. The magnetic field strength right next to a refrigerator magnet is 100x greater or more.
However, you then have to consider how quickly the magnetic field strength from the magnet decreases as a function of distance from the magnet. If you were to model the magnetic field from a refrigerator magnet as simply the field from a magnetic monopole, the magnetic field strength would drop off as the inverse square of the distance from the magnet. In reality, though, the refrigerator magnet, like any bar magnet, has an 'N' pole and a 'S' pole with opposite polarities, and so if you're at a distance from the bar magnet there is significant 'cancellation' between the 'N' pole and the 'S' pole (visualize the 'N' pole of a magnet as being a source of magnetic flux lines, and the 'S' pole as being a sink of magnetic flux lines) and so the magnetic field strength actually drops off as about the inverse cube of the distance from the magnet.
I'll leave it to you as an exercise to figure out how what the approximate magnetic field strength due to a magnet having a size of 1 inch and a surface field of 500 Gauss is at a distance of, say, 3 feet from the refrigerator. You should be able to see that it doesn't take much distance to reduce even a very large magnetic field at the surface of a bar magnet down to much less than the Earth's magnetic field strength of about 0.5 Gauss.