You can book tickets online in advance from different sites or you can directly go to the tomb site and buy tickets from the main counter.