Clean and Scrape Before You Paint
It seems counterintuitive to clean the windows first. But it's a good idea for two reasons. First, your paint job will last longer if the intersection of the glass and wood sash is sealed with paint. You can't get a good seal if the glass is dirty. Second, you'll get a neater paint job if you scrape off previous layers of paint and other crud that may be on the glass.
Use any window washing solution you prefer and a new, single-edge blade to clean old paint and gunk from the glass. Apply the solution, then scrape, to avoid scraping on dry glass. Never scrape dry glass. Grit pushed by the razor can scratch the window.
Remove the Sash
It's quicker and easier to paint the sash if you take it out of the window frame and rest it on sawhorses or a workbench. The sashes in most modern double-hung, sliding and casement windows are removable. The photo shows removing a casement sash. Most newer double-hung windows are removable by pivoting them in and twisting to release them. Old double-hung windows that are held in by wooden stops are more difficult to remove. It may not be worth the effort unless you're a perfectionist.
Sandpaper can scratch glass. And it's really easy to accidentally sand the glass where it meets the wood parts of the sash. You can either be extra careful when sanding along the glass, or you can protect the glass with masking tape. Avoid using a power sander along the edge of the glass because you'd be even more likely to scratch the glass.
Remove All the Hardware
This may seem obvious, but if you look around, you'll notice that a lot of painters skip this step. Remove latches and handles from double-hung windows. On casement windows, it's much easier to get a neat-looking paint job if you remove the operating hardware from the sash. Just be sure to keep track of the screws and other pieces. Take photos with your phone so you'll know how to reinstall the parts.
Start Early in the Day
Unless you live in an area free of bugs and criminals, you'll probably want to reinstall your window sashes and possibly close your windows for the night. And you can't really do that with fresh paint. So plan your paint job to allow time for the paint on the sashes to dry before nightfall.
Use a 1-1/2-in. Angled Sash Brush
Most of the areas you'll paint on a window aren't very wide, so a narrow brush will work fine and be easier to control than a wider flat brush. And the angled bristles of a sash brush are specifically designed to neatly apply paint in all of the tight corners and small spaces you'll find on a window. Of course, we always recommend spending a little more money for a top-quality brush and then taking care to clean and store it properly.
Avoid Painting the Tracks or Weather Stripping
Your window tracks and weather strips won't work correctly if they're covered with paint. In some cases, the easiest way to avoid painting these parts is to cover them with masking tape. If there's space, you can also slip a wide putty knife between the wood frame and the track to keep the paint off. If you do slop paint onto these areas, wipe it off right away with a damp rag.
Don't Bother to Mask the Glass
Covering window glass with masking tape is so time consuming that it's usually quicker to simply paint neatly along the glass with your brush. If you get a little on the glass, it's easy to scrape it off later with a razor blade. If you'd rather mask the glass, use a masking tape that has edge-seal technology to prevent paint from creeping under the tape.
Move the Sash Before the Paint Dries
This tip isn't as important if you've removed the sash from the window and waited until it's completely dry to reinstall it. But if you paint your sash in place, avoid a stuck window by opening and closing the window a few times before the paint dries completely. Return to the window about an hour after you've painted it and open and close it to break any paint seal that may have formed. You may even need to do this again the following day just to be sure everything is unstuck.
Paint Old Windows With a Bendable Pad
The upper sash in many old double-hung windows is painted shut, making it difficult to paint the lower rail. You could take time to free up the window, but this can be a big project. Another solution is to buy a Warner Bender Paint Pad from a paint store. Bend the metal to an angle that will allow you to apply paint. Then use a brush to spread some paint on the pad and carefully apply paint to the upper sash. It's tedious but necessary if you don't want to look at ugly drips every time you open your lower sash.