Nano-scale linewidth measurements are performed in semiconductor manufacturing and in the data storage industry and will become increasingly important in micro-mechanical engineering. With the development of manufacturing technology in recent years, the sizes of linewidths are steadily shrinking and are in the range of hundreds of nanometers. As a result, it is difficult to achieve accurate measurement results for nanometer scale linewidth, primarily because of the interaction volume of electrons in materials for an SEM probe or the tip size of an AFM probe. However, another source of methods divergence is the mathematical model of the line itself. In order to reduce the methods divergences caused by different measurement methods and instruments for an accurate determination of nanometer scale linewidth parameters, a metrological model and algorithm are proposed for linewidth measurements with AFM. The line profile is divided into 5 parts with 19 sections and 20 key derived points. Each section is fitted by a least squares straight line, so that the profile can be represented by a set of straight lines and 6 special points, or by a 20x2 matrix of fitted points and a 6x2 matrix of starter points. According to the algorithm, W T and W TF , W M and WMF, W B and WBF represent the widths at the top, the middle and the bottom of the line profile before and after the least squares fitting, respectively. A L and A R represent the left and right sidewall angles, and H represents the step height of the line profile. Based on this algorithm, software has been developed using MATLAB for the calculation of width and height parameters of the line profile. A NIST nanometer scale linewidth artifact developed at NIST's Electronics and Electrical Engineering Laboratory (EEEL) was measured using a commercial AFM with nanotube tips. The measured linewidth profiles are analyzed using our model, algorithm and software. The model developed in this paper is straightforward to understand, and provides a common set of parameters to evaluate the nano-scale line feature.