In addition to the strategic events outlined above to consider the battle a turning point, the Battle of Gettysburg was both a tactical and moral defeat for Lee and the Army of Northern Virginia. When Lee's army retreated from Maryland, it had suffered not only a loss in irreplaceable personnel but, perhaps more important, a loss in its sense of invincibility.
Up until the Battle of Gettysburg, Lee (and his troops) believed that his troops could--under almost any circumstances--defeat the Army of the Potomac. The Army of Northern Virginia, up to that point, had rarely been defeated in a strategic (its overall goals) or tactical (its fighting capability) sense. In fact, one could argue that the Confederate Army under Lee had yet to be completely beaten in a major battle up to July 3, 1864.
Lee's army, therefore, firmly believed that if they encountered the Federals on roughly equal terms they would win. The Battle of Gettysburg, which resulted in very similar casualties on both sides, proved to Lee and his army that the Federal army was willing to incur any level of losses in order to stop the Confederates, and this realization provided a psychological shock to the Confederates--an important turning point in their belief in their invincibility.
When the Army of Northern Virginia retreated into Virgina in the days following the battle, it left Gettysburg with the awareness that it had been beaten. Although many historians argue that the battle was a tactical draw, most consider it a strategic and psychological defeat for the Confederates.