The purpose of this paper is to present a numerical algorithm for solving the Lane–Emden equations as singular initial value problems. The proposed algorithm is based on an operational Tau method (OTM). The main idea behind the OTM is to convert the desired problem to some operational matrices. Firstly, we use a special integral operator and convert the Lane–Emden equations to integral equations. Then, we use OTM to linearize the integral equations to some operational matrices and convert the problem to an algebraic system. The concepts, properties, and advantages of OTM and its application for solving Lane–Emden equations are presented. Some orthogonal polynomials are also used to reduce the volume of computations. Finally, several experiments of Lane–Emden equations including linear and nonlinear terms are given to illustrate the validity and efficiency of the proposed algorithm. Copyright © 2012 John Wiley & Sons, Ltd.