Train from Krakow
: times, details and fares in English on the official Polish railway website:https://www.intercity.pl/en/
Bus is a bit faster but traffic is always unpredictable. Times, details and fares in English on:https://en.e-podroznik.pl/
If the time difference is less than an hour I'd always choose train over bus because of the traffic aspect.