When Maj. Gen. George G. Meade reorganized the Army of the Potomac in 1864, Wainwright became chief of artillery of V Corps, replacing Augustus P. Martin. He served in that role to the end of the war. Among his most successful actions was using guns to break a Confederate attack at the Battle of North Anna. He was promoted to brevet brigadier general on August 1, 1864.