Answered by Jose | Feb. 21, 2018 21:15
Yes, it is possible. But I think the time will be a bit tight if you visit both Longmen Grottoes and Shaolin Temple on your own. There are many high speed trains available between Xian and Luoyang. It is suggested that you take an early morning train to arrive at Luoyang Longmen Railway Station. Upon arrival, you can take bus no. K71 from the train station and get off at Longmen Grottoes. The taxi fare is around CNY15.
Shaolin Temple is about 2 hours' drive from Luoyang city. You may go to Luoyang Bus Station (located close to Luoyang Railway Station) to take regular bus bound for Xuchang/Xinmi. The bus stops by Shaolin Temple. It departs every 30 minutes from 05:20 to 15:30 and the bus fare is CNY24.
For your reference, the recommended visiting time is 3 hours for Longmen Grottoes and 3 hours for Shaolin Temple. To save time, you may also consider chartering a car to take you to the Shaolin Temple or join in the guided day tour.