From Military History Online:
Yet the Maginot Line was defeated twice in just four years. The first defeat occurred in May and June of 1940 as a result of the inevitable German invasion. However, on this occasion, the Maginot Line was defeated not by assault but by a massive German mechanized outflanking maneuver which forced the collapse of the French military, the hasty but miraculous extrication of British and French forces at Dunkirk, and the surrender of the French nation. The Germans were able to overrun or capture only a handful of the smaller Maginot forts and none of the large ones. The majority of Maginot Line defenders surrendered only after their nation had done so first. Four years later, the Maginot Line again was defeated. This time, the U.S. Army overran and captured Maginot Line forts from the Germans in a series of operations during the fall of 1944 and the spring of 1945. Though the U.S. Army had little difficulty with the Maginot Line overall, several of the forts posed a quite challenge to capture. Ultimately the U.S. Army was able to overcome stiff German resistance, difficult terrain and poor weather to capture these several still formidable Maginot Line forts.