In order to truly understand Shakespeare's attitude to war is, one must look at this play, Henry V in context. In the eight plays from Richard II-Richard III, Shakespeare explores war, from Henry IV usurping the throne from Richard II and his fight to keep the throne, to the Hundred Years War with Henry V and Henry VI, to the War of the Roses with Henry VI to the end of the war with the defeat of Richard III.
He shows the many faces of war from the heroic to the cowardly and from patriotism to horrors of war for everybody concerned. War effects everybody and it isn't pretty.
As a character we have seen the young prince grow from Prince Hal in Henry IV parts 1 & 2 into a hero in Henry V. One of the pieces of advice he gets from his father is to fight in a foreign war which will unite his country against a common enemy. Henry's claim to the French throne was not weak. It was legitimate.
Although in some of his history plays, Shakespeare bent and stretched the truth to tell his story, the actual facts of the Battle of Agincourt are reported in the play. Henry was not looking for a fight. He was trying to get his weak and hungry army back to Calais, then home to regroup.
The French army, on the other hand was fresh and ready for a fight. They out numbered the English army. Providence was on the English army's side. It had been raining, the ground muddy. Henry deployed his Welsh long bowman on the hillsides behind a barrier of wooden spikes that would impale any French horse and rider to make it through. When the battle began, it was like shooting fish in a barrel for the bowman. Under the constant barrage of arrows raining in, horses and riders slipped down on the muddy battlefield. Mounds dead French horses and knights filled the valley. The result was the loss of most of the French battle commanders and thousands of men. The English losses were under a 100.
The slaughter of the boys who were unarmed at the camp actually happened and Henry actually did order the French prisoners killed.
As a military king, Henry did not punish the cities he conquered. Looting was forbidden. His logic was that these people were his citizens and therefore should treated with respect.
Shakespeare understood the affects of war and depicts them throughout his history plays. Henry is one of the good guys. We see him struggle with the whole question of what gives him the right to ask the men under his command to die for him.
He was a great leader. His men respected and followed him.
Although there are times in William Shakespeare’s tragedy Henry V, where the dialogue seems to be glorifying war, the author’s message becomes clearly the opposite. Young Henry has been duped by his advisers into entering a war with little cause, and he blindly leads his men into the fray. Shakespeare highlights the nonsense behind many wars and the near brainwashing soldiers receive both in training and on the battlefield. This theme peaks with the St. Crispin’s Day speech (act IV, scene iii) wherein Henry proclaims to his “brothers” that they will, in fact, receive a greater honor in that there are so few of them going into the battle. The ridiculous and far unrealistic body counts of the French wounded, captured and dead that follow (when juxtaposed with the count of the English casualties) seal Shakespeare’s stance that war is futile, thoughtless, and barbaric.
To add to previous answers,
I think that Shakespeare could be on both sides. Initially, the surface reader will see that Shakespeare sees war as a glorious and patriotic endeavor in this play. His use of rhetorical blackmail robs the army of their manlyhood if they refuse to fight. In Act IV Scene 3, Henry says that if a man was not with him, he was not a man.
On the other hand, that fact that Henry used rhetoric could suggest he was manipulative and that soldiers are brainwashed to fight.