In last decade, data classification become more famous which aims to classify the data to a fixed number of classes. The data classification problem is treated as an NP hard problem and different optimization models are presented to resolve it. This paper introduces a social spider optimization (SSO) algorithm with tumbling effect called SSO-T algorithm to solve the data classification problem. First, the SSO algorithm is derived to solve the classification process which is considered as a NP hard problem. Next, to further enhance the exploration process of SSO algorithm, it is modified by the inclusion of tumbling effect, called SSO-T algorithm. For validating the results of the SSO and SSO-T algorithm, a real time problem of stock price prediction (SSP) is employed. For experimentation, the results are validated by testing the SSO and SSO-T algorithms against four datasets such as Dow Jones Index (DJI) dataset, three own datasets gathered from Yahoo finance on the basis of daily, weekly and yearly. The empirical result states that the proposed algorithms perform well and it is noted that the classification performance of the SSO algorithm is increased by the inclusion of tumbling effect.