The Second Battle of Kernstown was fought on July 24, 1864, at Kernstown, Virginia, outside Winchester, Virginia, as part of the Valley Campaigns of 1864 in the American Civil War. The confederate Army of the Valley under Lt. Gen. Jubal A. Early soundly defeated the Union Army of the Kanawha under Brig. Gen. George Crook and drove it from the Shenandoah Valley back over the Potomac River into Maryland. As a result, Early was able to launch the Confederacy's last major raid into northern territory, attacking the Baltimore and Ohio Railroad in Maryland and West Virginia and burning Chambersburg, Pennsylvania, in retaliation for the burning of some civilian houses and farms earlier in the campaign.