Investment is an investment activity within a certain period with the hope of getting a profit. Things that need to be considered by investors when investing are not just yields (return), but investors need to consider the purpose of the investment and the investment period. This study optimizes the formation of portfolios by utilizing the predicted value of stock prices using LSTM. The test used five daily stock indices from LQ45, namely BBCA, BBRI, TLKM, UNVR, and BMIR, from April 2010 – April 2020. The portfolio was built using the Genetic Algorithm and Equal-Weight (EW) method. Portfolio of Genetic Algorithm and Equal-Weight (EW) without predictions used as a benchmark. The experimental results show that using the LSTM prediction and Genetic Algorithm can produce an optimal portfolio with the highest Sharpe ratio value at 1.3950.