Why doesn't Jarl Balgruuf side with the StormCloaks?
Jarl Balgruuf is a devout worshipper of Talos, who hates the Thalmor and the White-Gold Concordat. However, he is also a pragmatist who believes that ensuring the physical safety of his subjects is his primary duty.
He's Conflicted
The conflict between these two urges causes the Jarl a great deal of consternation, and he spends the first part of the game trying to make up his mind. In response to the question "Whose side are you on?", he says
If it's the war you're referring to, I'm on the side of Whiterun. No doubt General Tullius and his friends in the Empire will tell you that I owe them my loyalty, and perhaps I do. Ulfric Stormcloak would say that I owe my allegiance to the Nord people as they fight for Skyrim's independence. Perhaps this is also true. The day might come when I am forced to draw my sword for one side or the other. But that day has not come yet.
But in the end he chooses peace and safety.
A planned but unused conversation with Vignar Grey-Mane:
Balgruuf: "I won't say it again, Vignar; Talos worship is forbidden. It's the Empire's law, and we're still a part of the Empire."
Vignar: "A law made at the tip of an Aldmeri sword, aye. A sword stained red with Nord blood. Is this what our people fought and died for? To forsake our most beloved ancestor and divine?"
Balgruuf: "I'm no happier about this than you are, but I don't want the see the Thalmor rounding up people in the streets and throwing them in prison."
Another conversation with Vignar, after the batte of Whiterun:
Balgruuf: "A convenient position to hold now. But mark my words, old man, in the days to come, Ulfric will spread his rebellion thin. And what then? We need the Empire, as much as it needs us. We Nords are the Empire! Our blood built it. Our blood sustains it! You of all people should know that."
Vignar: "If this was my Empire, I'd be able to worship whoever I damned well pleased. You wish to see an Empire without Talos? Without its soul? We should be fighting those witch-elves, not bending knee to them. The Emperor is nothing more than a puppet of the Thalmor. Skyrim needs a High King who will fight for her, and Whiterun needs a Jarl who will do the same."
Balgruuf: "Tell me, Vignar. Was all this worth it? How many of those corpses lining our streets wear the faces of men who once called you friend? What about their families?"
He also makes clear his opinion of Ulfric and the consequences of his uprising, when asked "What will it take to end the war?":
Ulfric Stormcloak's head on a pike. Do you think Ulfric really cares about Skyrim's independence, or the welfare or its people? I promise you, he doesn't. He's nothing more than a barbarian renegade, whose lust for power has cost the lives of countless innocents.
So, Balgruuf believes that the Nords need the Empire's help to defend themselves from the Thalmor. An independent Skyrim would lack that protection. Furthermore, an independence won through civil war would leave Skyrim weakened and alone.
Because he sees no better choice.
So, although he detests the current situation, he believes it's better than being invaded and conquered. He simply doesn't believe that killing each other helps the Nords' cause.
Based on the comments made during the game, Balgruuf takes his role as Jarl really seriously and all personal feelings are secondary to making sure Whiterun is looked after.
Ulfric wants a civil war and to separate from the Empire but Balgruuf is happier with the way things are especially with his concern about threats posed by dragons.
The Empire and the Nords have a defensive pact and close economic ties. He does not like the Empire especially, but tries to stay neutral within the civil war until Ulfric forces his hand.
Also there are hints that he has had personal disagreements with Ulfric in the past.
I highly recommend checking out http://elderscrolls.wikia.com/wiki/Balgruuf_the_Greater - it gives all the relevant conversations from the game.