Dr. McGuire joined "The Winchester Rifles," Company F of the 2nd Virginia Infantry as a private in the Confederate Army. However, his services were much more valuable as a doctor rather than a front line soldier. McGuire was made a brigade surgeon and was ordered to report to General Thomas J. Jackson at Harpers Ferry. Jackson initially scoffed at McGuire's youth, but the two became very close as the war progressed. Dr. McGuire treated General Jackson after the First Battle of Manassas, where the General picked up the nickname "Stonewall Jackson" following an exclamation by General Barnard E. Bee Jr.. In 1862, McGuire was promoted to the chief surgeon of Jackson's Corps, serving in the Army of Northern Virginia under its Medical Director, Dr. Lafayette Guild. While attached to Jackson's corps during the Second Bull Run Campaign, McGuire amputated Jackson's subordinate Richard Ewell's leg after Ewell was wounded at the Battle of Groveton. In May 1863, Jackson was gravely wounded by friendly fire while performing a reconnaissance during the Battle of Chancellorsville. The severity of the wounds required Dr. McGuire to amputate Jackson's left arm. Jackson died of pneumonia a few days later. His last words were recorded by Dr. McGuire as: "Let us cross over the river and rest beneath the shade of the trees". The death of Jackson affected McGuire greatly. He would always remember Jackson with the deepest reverence and served as a pallbearer in Stonewall's funeral. During the Second Battle of Winchester, which was part of Robert E. Lee's invasion of Pennsylvania, McGuire served under Richard Ewell. At the Battle of Gettysburg, Dr. McGuire amputated the leg of General Isaac R. Trimble after Pickett's Charge. He later served under General Jubal Early. McGuire was captured at the Battle of Waynesboro in March 1865, but was released and rejoined the Army of Northern Virginia. He was present at the surrender at Appomattox Court House. After the War, McGuire contributed to the original of the Geneva Conventions, which is why the Boston Medical Journal said in his obituary that he had "humanized war."
Post Civil War
McGuire married Mary Stuart of Staunton. Her father, Alexander Hugh Holmes Stuart, was a U.S. Congressman and Secretary of the Interior before the Civil War. Mary was a cousin of General Jeb Stuart. She and Hunter had nine children. McGuire wrote the introduction of The Old Plantation: How We Lived in Great House and Cabin before the War, a 1901 authored by James Battle Avirett. He lived at 5th and Grace St. in downtown Richmond, had a summer residence in Bon Air, Virginia, and a house in Henrico County. After the war, McGuire served as president of the American Medical Association.