By considering learning effects during the process of maintenance, this article investigates an availability-based warranty policy from the manufacturer's perspective. Imperfect preventive maintenance activities are implemented to reduce the number of equipment failures so as to meet the product's availability requirement and minimize warranty servicing cost during the warranty period. Hybrid hazard rate model is used to describe imperfect preventive maintenance actions; maintenance plan and warranty servicing cost are optimized by considering learning effects. Preventive maintenance schedule within a warranty period is optimized cycle by cycle, and the warranty cost rate is minimized under the requirement of availability within each cycle. Numerical example of a wind turbine gearbox is provided to verify the effectiveness of the proposed availability-based warranty policy. Sensitivity analysis shows that by considering learning effects on maintenance, the gearbox can maintain a higher availability level with a lower warranty cost than the case without consideration of learning effects.