Masking for repair or respray
Remove dust, etc. from the repair area prior to beginning masking, preferably by using compressed air to blow dust and water away, particularly from beneath trims, mouldings and panel edges. Time spent at this stage will remove the risk of dust or water being blown out onto the wet primer or paint surface. Use lint-free absorbent cloth, finishing with a "tack cloth" immediately before applying primer/paint.
Ensure edges to be masked are clean and dry before applying masking tape, to avoid the tape peeling back during the painting process. Tape all edges of window seals, mouldings and adjacent panel edges before using paper to cover larger areas. Apply tape to the exact edge of the moulding or panel, with no overlap in either direction. If in doubt, practice a little or get someone with better eyesight to do it! Note: some cheaper brands of tape might not be as willing to stretch around corners and sharp mouldings!
Depending on which parts of the car are to be painted, mask inside door openings or bonnet/tailgate openings. This prevents overspray from spoiling doorshuts, etc., and also helps prevent dust from blowing out of these areas. Make sure that any tape edges do not extend on to the exterior panel surfaces, as a hard paint edge will then be left when the masking is removed.
Adhesive soft sponge tape is available from motor factors especially for masking gaps between door openings, etc., but it is quite expensive.
Masking to prevent extended overspray
Mask the surrounding area by covering any exposed paintwork, mouldings, glass or bumpers within a minimum of two feet if using aerosols. If using professional type sprayguns a much larger area will need to be protected. Start the masking from an inch or so beyond the sanded area. If primer is applied to unsanded paintwork it will be impossible to "feather-edge" the repair due to poor adhesion of the primer to the unprepared surface. When joining additional sheets of paper to each other, use masking tape along the full length of the join, otherwise a surprising amount of overspray can collect on the panel beneath the paper.
Likewise, a much tidier finished repair is obtained by masking wheel arch openings to protect inner arches, plastic liners and mechanical parts from accidental overspray.
Finally, don't forget to cover wheels and tyres if needed, either with normal masking methods or proprietary wheel-masking covers.