Automated slideshow creation techniques can help in arranging various multimedia elements, such as photos, videos, and graphics, into a cohesive and engaging story. This paper specifically focuses on utilizing metaheuristic algorithms to create compelling slideshows based on a predetermined set of photos. The work presents a two-stage algorithm for solving the photo slideshow problem as defined in the qualification round of Google Hash Code 2019. In the first stage, a Genetic Algorithm is applied to produce a good-quality initial solution. In the second stage, an Iterated Local Search metaheuristic is used to further optimize the solution. Additionally, an Integer Linear Programming model is presented for comparison purposes, which is used to solve a subset of instances that are of smaller sizes. The computational study uses a challenging test set of four instances and demonstrates that the proposed approach produces comparable results to the best performing algorithms in the competition. For two of the instances, new benchmark results are obtained. Furthermore, the proposed solution is tested on a newly generated test set of 55 instances, consisting of real-life and synthetic data. The results indicate that the proposed approach can effectively produce solutions of good quality for smaller instances and efficiently solve larger instances within a short period. © 2023, The Author(s), under exclusive licence to Springer Nature Switzerland AG.