You should take the GRE no later than three weeks before the application deadline.
Scores received after the deadline will still be matched to your application; however, faculty may have already begun their review of your application without your test scores. There is no guarantee that test scores received after the deadline will be seen by the committee. You are advised to have all scores sent by the deadline for the fullest consideration.
Refer to the Deadlines and Fees page on the Graduate School website for deadline information by academic department and program.