Copyright is created automatically as soon as a work is in tangible, fixed form.
If you mean registering your copyright, then you can do that at any point after you create it.
There are a couple caveats to that-
1) You MUST register a copyright before initiating an infringement suit.
2) Registration done within 5 years of publication creates prima facie evidence of the facts contained on it
3) Registration done before infringement commences preserves the availability of statutory damages and attorney's fees.