This paper deals with the design of an autopilot based on sliding mode control combined with feedback linearization method for an autonomous sailing vessel. This autopilot is developed using a model with four degrees of freedom, which represents the dynamic of a sailboat. Due to the high nonlinearity of the developed dynamic model, heading and sail opening angle controller were developed to steer the sailboat toward a specific target position. The nonlinear four degrees of freedom dynamic model for the sailing vessel is first described. Then, an autopilot is designed using both sliding mode control and feedback linearization method. Finally, some simulations are carried out to illustrate the behavior of the overall system.