In view of the existing resource bottlenecks in current e-commerce applications, combined with the application background of grid technology, a grid technology mode under the application of e-commerce mode is proposed, which specifically states its architecture and layered characteristics. Using mathematical analysis, the traditional grid technology is optimized and improved. Emphasizing the close grid optimization, the grid closely around the initial grid is greatly affected and the grid nodes are optimized and adjusted. Improved grid algorithm adjusts the overall grid, in which any grid node is adjusted by other nodes and the cost is calculated for a long time. In order to make full use of the advantages of traditional grid technology and also consider key factors to improve the computing efficiency, the improved grid algorithm makes the quality of optimized grids very close to the traditional grid technology. Using a simple application mode, the application characteristics and development in the future of e-commerce with grid technology mode is analyzed.