This paper presents a novel numerical procedure to predict nonlinear buckling and postbuckling stability of imperfect clamped–clamped single walled carbon nanotube (SWCNT) surrounded by nonlinear elastic foundation. Nanoscale effect of CNTs is included by using energy-equivalent model (EEM) which transferring the chemical energy between carbon atoms to mechanical strain energy. Young’s modulus and Poisson’s ratio for zigzag (n, 0), and armchair (n, n) carbon nanotubes (CNTs) are presented as functions of orientation and force constants by using energy-equivalent model (EEM). Nonlinear Euler-Bernoulli assumptions are proposed considering mid-plane stretching to exhibit a large deformation and a small strain. To simulate the interaction of CNTs with the surrounding elastic medium, nonlinear elastic foundation with cubic nonlinearity and shearing layer are employed. The governing nonlinear integro-partial-differential equations are derived in terms of only the lateral displacement. The modified differential quadrature method (DQM) is exploited to obtain numerical results of the nonlinear governing equations. The static problem is solved for critical buckling loads and the postbuckling deformation as a function of applied axial load, curved amplitude, CNT length, and orientations. Numerical results show that the effects of chirality angle and curved amplitude on static response of armchair and zigzag CNTs are significant. This model is helpful especially in mechanical design of NEMS manufactured from CNTs.