There are several ways to reach Sakamoto and Mount Hiei.
From Kyoto, the JR Kosei line goes directly to the Hieizan-Sakamoto station which is a 1,200 meter walk from the Sakamoto Cable Car or the trailhead to climb Mount Hiei on foot. Alternatively, take the Keihan Main Line to Demachiyanagi and transfer to an Eizan train to Yase-Hieizan-guchi (八瀬比叡山口). From here the Eizan Cable Car makes the trip to the top of Mount Hiei for ¥530/1040 one-way/return (incl. the ropeway: ¥820/1640 one-way/return), every 30 minutes daily from 8:30 to 17:30 (or longer, schedules vary a bit depending on the season). The last leg of the trip to the summit is a 3-minute ride on a ropeway, which departs at intervals of 10-20 minutes between 9 am and 6 pm.
Alternatively, you could also take the Keihan Line to Sanjo Station and transfer to the Tozai Line bound for Hamaotsu Station in Otsu. From Otsu, you can take the JR Kosei line or Keihan Ishiyama-Sakamoto line to Sakamoto, although the Keihan station (the last station on the line) is more centrally located. The Hiyoshi Taisha shrine and the cable car to Mt. Hiei are about 15 min away on foot, both fairly well signposted.
Be careful: there are two different cable-cars up the hill, each ran by a different company. So, if you buy a two-way-ticket from one company, you cannot use this for the other railway and you’ll need to buy a new ticket.
There are occasional direct buses from Kyoto station directly to the top, taking about 1.5 hours and all departing in the morning. Schedules are severely curtailed in the winter.
Both Sakamoto and Mt. Hiei are best covered on foot. For going between the two, you can use the Sakamoto Cable Car, which costs ¥840/1570 one-way/round-trip and runs daily from 8 AM to 5 PM once every 30 minutes. At over 2 km, this is the longest cable car in Japan and takes about 11 minutes for the journey. This cable car line was built in 1927 and refurbished in 1993. The European style cars have large windows with wonderful views of Lake Biwa.
If walking is preferred, it’s a 600 metre climb which starts as a convenient path of mossy steps known as Honzaka (本坂), starting from Sakamoto by the side of the Hayao shrine, but soon degrades into a steep stony gully that climbs nearly 600 metres in just over 3km. You need a reasonable degree of fitness and some good shoes. In wet weather it would be very slippery. Nevertheless the walk through the forest is well worth the effort. There are also many other routes, with numerous small temples and waterfalls along the way, but stick to the main gully and track and you won’t get lost. You may see monkeys along the way as well.