The quality of the steel surface is a crucial parameter. An improved method based on machine vision for steel surface defects detection is proposed. The experiment is based on 20 images for each of 6 distinct steel defects, a total of 120 defective images achieved from the detection system. 128 different features are extracted from the images and feature dimensions are reduced by the principle component analysis (PCA) based on the sample correlation coefficient matrix. Hierarchical clustering by Euclidean distance is implemented to find defect characteristics differentiation, the steel surface defects are classified based on directed acyclic graph support vector machine (DAG-SVM). The experimental results indicate that this method can recognize more than 98 % of the steel surface defects at a faster speed that can meet the demands on the steel surface quality online detection