The following year, Hawley commanded a brigade under General Truman Seymour in the Battle of Olustee in Florida. He and his men were reassigned to the front lines in Virginia as a part of Terry's Division, X Corps, Army of the James. He was in the battles of Drewry's Bluff, Deep Run, Derbytown Road, and other actions near Bermuda Hundred and Deep Bottom. With openings created by battlefield losses and reassignments, Hawley commanded a division during the Siege of Petersburg and was promoted in September 1864 to brigadier general of volunteers. Concerned over keeping the peace during the November elections, Hawley commanded a hand-picked brigade shipped to New York City to safeguard the election process.