1. Most electric guitars and basses can go on board as a carry on in a gig bag, but if you must check your instrument, be sure it is in a good hard case and firmly packed. You don't want any movement inside the case. Pack all open areas with bubble-wrap, t-shirts or towels, or newspaper. Shipping guidelines apply here, if you're familiar with that. Take your picks accessories out of the case and put them in your regular luggage.
2. Loosen the strings. Just a quarter turn is fine. If you slack them all the way, you may find your neck in need of adjustment, when you reach your destination.
3. Get a humidifier. The Humitar by Music Nomad and Planet Waves Humidipak, are good ones.
4. if you have an expensive or valued instrument, consider Travel insurance. Choose a provider that includes loss or damage to valuables.
5. Lastly, a trick I have used on longer flights with a gig bag, is to fashion a wire hanger into the zippered headstock area of the bag, and place a dark suit-bag cover over the case. Walk on and hang it in the closet as you enter, or place it on top of luggage in the overhead. It's amazing how attitudes can change when the idea of a musical instrument is changed to clothing.