At the Battle of Gettysburg, his two regiments of sharpshooters played an important role in delaying Confederate attacks on Devil's Den and the Peach Orchard. In a sharp encounter in Pitzer's Woods on Seminary Ridge, the 1st U.S. Sharpshooters stalled the advancing Alabama brigade of Cadmus Wilcox. Berdan assumed command of J. H. Hobart Ward's brigade when the latter became acting division commander (David B. Birney having become acting corps commander following the wounding of Daniel Sickles) and led the division throughout the rest of the campaign, as well as during the subsequent Bristoe and Mine Run campaigns.