So many things could happen in your life and in your husband's life, that sadly there's no fool-proof way to prevent divorce. But I'd say the best strategy would be to take your time before getting married. Don't just date someone for a couple years, or even a few years - date them for SEVERAL years! Marry them only after you've seen them at their best AND their WORST.
Another good tip is to make sure you find someone you can argue with respectfully and compassionately. Bad times will come, so you want to know your partner won't treat you like crap or be a terrible communicator or unable to make changes, etc etc. On that note, always be the best girlfriend YOU can be as well. Be kind, and respectful, and loving, even in hard times, even in fights! And make sure your boyfriend is the same.
If things start to go bad down the road, make sure you and your boyfriend are both the types who would seek help from a counselor. Nobody's perfect, but that's why there are people to help us, if we allow them. Make sure you're both willing to have help and not just accept badness as something unfixable.
I'm sure this one's a given, but of course, don't give up. :) Go into it believing that divorce is not an option, that you will work through absolutely anything. Before you get married, make sure your husband-to-be has the same attitude towards marriage and divorce as you do.
Speaking of attitudes, make sure you have the same values! Before you get married, talk about your beliefs and opinions on everything and anything, and talk about possible problems BEFORE they become problems: to have children or not, how to raise them, what to do if someone loses a job, how to handle money, where to live, what to do if one of you needs to move, what to do if someone cheats (it must be talked about, even if you don't think it will happen), sexual compatibility, religious beliefs, political beliefs, etc etc etc!
I should mention though that sometimes divorce is for the best, because two people are just wrong for each other and are making each other miserable. But if you pick the right person and take your time, hopefully that won't happen in the first place. :)