If you are lucky, the pins have only worn through the bushing and have not yet ovaled out the bushing holes. If so, you may be able to do the swap on the car. If it's necessary to weld in and redrill the holes, that is easiest off the car. Support the open door so it does not sink (as in a leaky floor jack). Mark around the hinges and start with the upper one (most likely to wear). Be aware that the three bolts go into square nut plates inside the door frame. They will want to drop within their individual pockets, so that is why you want to mark them before removing them one hinge at a time.
Use a door spring compressor tool and remove the door spring, then tap out the hinge. Some hinges may have a pin retainer sleeve with a couple tabs that stick out. Press them in and tap out. Tap out the bushings and gently file down any burrs. As needed, MIG a few beads in the ovaled out area and then carefully file the hole round again. JB Weld will NOT last more than 5 minutes, so don't waste your time considering this.
I didn't remember to take photos until after I had reassembled the hinges, but you can see that I had to restore the hole to round.
If you don't plan to repaint the car, now is a great time to paint the hinges with a rattle can so the welded-in section is protected from future rust. If you are lucky, the hinge will go back into place and the door will remain aligned. Whatever you do, don't take them both off at the same time. It was years until I had the skills to realign the door after I made this mistake.