Score around the edges of the interior trim surrounding the window frame with a utility knife to break the paint seal.
Slide a flat bar underneath the interior window trim and pry off each piece. Pull out any stray nails from the window frame with a nail puller.
Open the window sash so that the sill is exposed. Saw through the center of the sill using a reciprocating saw.
Slide the flat bar underneath each half of the cut sill and pry it up. Once the sill is pried up, the window will slide free from the window opening.
Pull the window from the window opening from the exterior of the house. Be careful not to damage the exterior of the house as you pull the window from the opening. Set the window aside. You may choose to either discard the entire window or remove the sash and sell it to a salvage yard.
Remove any stray nails from the removed window opening with a nail puller. Brush off the framing boards around the opening with a wire brush.
Caulk along the base of the window opening with using a caulk gun equipped with window and door caulk. Apply a generous zigzag bead of caulk along the base of the window opening.
Pivot the replacement window into the window opening from the exterior side. Seat the sill firmly over the base of the window opening so it rests in the the bead of caulk.
Place a level across the top of the window sill. Adjust the window for level by sliding wood shims underneath the sill.
Drive coated screws through the center of the sill into the window frame base every 4 to 6 inches with a screw gun. Saw off the ends of the wood shims flush with the exterior of the house using a hand saw.
Fill in any gaps underneath the sill with expanding spray foam insulation. Allow the insulation to cure for 24 hours and trim it flush with the exterior of the house using a utility knife.