If it rains, be warned that you might be walking 1.5-2 hours in the desert to get from Mogao Grottoes to the shuttle buses or any other form of vehicular transport! That was what happened to us. The river at Mogao Grottoes was a raging Milo-looking mess and the bridge was washed out, we had to walk a long way to get to the public buses to get back to town -- same goes for the tour buses. I wasn't happy at not being able to see the grottoes (on the insistence of my travel companion to not "waste" my money since I'd visited previously) and still had to walk across the desert, in the hot sun, with my backpack!
Sandstorms are very unpleasant (like thick orange fog with added grit and strong winds), and should one occur, all doors and windows have to be closed, and the Mogao caves will be closed to visitors (to protect the cave paintings from the sand, and also for the safety of the visitors).
We were told that sandstorms generally only happened in April, but we witnessed one in July. It is probably a good idea to allow enough slack in your itinerary so that you can reschedule a visit to the Mogao caves for the following day if necessary.
If you want to buy a guide book locally, note that the big book (“Dunhuang and Silk Road” by Sea Sky Publishing House – with a buff coloured cover) is unintelligible. It is written in English, but the language is so difficult to follow that it is basically useless. If you don’t believe me, try understanding this short piece (about the Sleeping Buddha cave): “Sakyamuni, to be dead before long, was being there lying serenely, percieving his disciple’s grieved howls by his deva ears and looking at this combative battlefield containedly by his deva eyes.” It seems to have been translated by someone who has never actually used English and did it word by word from a dictionary!
It is rather sad that the Chinese-produced guide-books completely ignore much of the ‘history’ of the caves, preferring to gush with superlatives and hyperbole. By making everything so wonderful, the books are impossible to use to see or understand the true highlights. The Mogaokou are presented as some kind of flawless perfection, rather like the airbrushed retouched photo of a supermodel, so diluting the true story and the fascinating ‘texture’ of Dunhuang and its art. It shouldn’t be the case, but the only decent lay and specialist guide books are printed overseas. Much the same can be said of all guidebooks about China: the utter inability to print anything but sycophantic stuff about how great/beautiful/wonderful/perfect everything is simply tedious. Frances Wood, Judy Bonavia or a handful of others manage to covey more history, romance, glamour and real perspective in a few simple sentences than the copious paragraphs of honeyed goo that the Chinese writers dish up.
Roads to Yardang Geological Park and to Jiayuguan are terrible in some parts, so take some motion sickness medication if you're prone to carsickness. The situation to Jiayuguan should improve when the new highway is completed, but I don't know when that'll be. The road journey to Jiayuguan took about 6 hours when we went (mid-Feb 2006).
Don't think dunes are a piece of cake! There is a big walk up to the top, and the heat is on normally.
The best time to climb is in the evening, just before sunset, as you will have the chance to see the sunset from above, and is a bit cooler...