The Battle of Seven Pines, also known as Fair Oaks, was the climax of Union Army of the Potomac commander George McClellan's famous Peninsula Campaign. McClellan's strategic vision was to use an amphibious movement to outflank the Confederate Army of Northern Virginia, Joseph Johnston commanding, and advance with a significant force on Richmond, the capitol of the Confederacy.
McClellan's advance was met with greater resistance than he had expected, and his pace was slowed enough that Johnston's force was able to effect a withdrawal from its advanced position near Washington to position itself to defend Richmond against the Army of the Potomac. Several tactical Union victories at Yorktown, Williamsburg, and Norfolk gave McClellan the confidence to continue the advance, albeit at a much slower pace than he had originally anticipated.
Johnston, knowing that he could not sustain a protracted siege if McClellan was to advance on Richmond, opted instead to go on the offensive, and he organized an assault on the Federal position at Seven Pines in Henrico County, Virginia.
McClellan's line was bifurcated by the Chickahominy River, as he expected reinforcements from Fredericksburg to the south, and at the opening of the battle, two of his corps were isolated on the southern bank of the river while the majority of his force was deployed to the north. Johnston opted to attack the two isolated corps on the Federal left, or southern, flank and turn the flank, leaving the northernmost three Federal corps to be pinned against the river and overwhelmed.
Johnston's plan was to divert McClellan's focus by engaging the three corps north of the river while allowing James Longstreet to coordinate the main action on the isolated two corps, commanded by General Erasmus Keyes on the left flank. The plan was confusing, and Johnston failed to effectively communicate his intentions to his corps commanders, Longstreet included. The result was a badly mismanaged and costly engagement.
Longstreet, by virtue of a wrong turn, ended up engaging the Federal left on a narrower front than the overall plan allowed for, and delaying the opening of the offensive by some 5 hours. Confederate General D.H. Hill became impatient and intiated the action without word from his superiors. Despite these early blunders, Hill was able to dislodge the Federals from their defensive line at Fair Oaks Station and force them to withdraw to a secondary position at the Seven Pines crossroads.
Longstreet reinforced Hill several hours later, and he renewed his assault on the Federal left, forcing another withdrawal.
As Longstreet renewed his assault, he send word to Johnston to join the attack. Johnston took several brigades from General William Whiting's division and attacked the right of Keyes' line. Keyes resisted, and were reinforced by Gen. John Sedgwick after a treacherous crossing of the last bridge over the Chickahominy. The other bridges had been burned by the Confederates, and heavy rains in the preceding days had caused the river to swell.
Sedgwick's division supported the defenders of Keyes' right, still at their positions near Fair Oaks Station.
The fighting that ensued was prolonged, desperate, and bloody. Joseph Johnston himself was wounded and taken to the rear, and the following day, as the Confederates renewed their assaults against now-reinforced Federal positions, President of the Confederacy, Jefferson Davis, appointed General Robert E. Lee to command the Army of Northern Virginia.
The continued Confederate attacks made no progress, and the Federals counterattacked in the late morning, forcing the battle-weary Confederates to retire from the field.
The fighting exacted a toll of roughly 5,000 Union and 6,000 Confederate casualties, and both sides claimed a victory. The Army of Northern Virginia withdrew to Richmond, and Lee reorganized to launch a counteroffensive against McClellan's stationary army. The Confederates launched a series of attacks known as the Seven Days Battles, which pushed the Federals off the Virginia Peninsula, back to the James River.
Richmond would not fall for three more years.