You can and should do a preliminary inspection yourself, but a self-inspection should not replace a professional marine survey for significant purchases. Do-it-yourself inspection tips: press firmly on all deck areas looking for soft spots, check the bilge for standing water or oil sheen, look at engine hours and oil color, examine the hull from waterline down for damage or repair patches, and run the engine at various RPMs while listening for unusual sounds. Your self-inspection helps you decide whether to invest in a professional survey.
