A space heater in space could only transfer its heat through radiation instead of conduction and convection, so only a small portion of its heat would escape. It would get hotter and hotter until it melts and stops working.
Essentially, that's how the ISS regulates temperatures. It has big external panels that radiate excess heat into space because there's very little matter up there to conduct heat away.