Jodhpur airport is the closest airport which is 275 km from the city which means 5 to 6 hrs drive.
Jaisalmer is well connected to most of the Indian cities via wide network of trains.
There is no direct bus from Jaisalmer to big cities so one has to switch bus at Jaipur from where state-run sleeper coach serves regularly.
If you are planning to hire a taxi or self drive to reach this place then taking rest at Jaipur or Ajmer is good. Hotels are easily available at these places.