Your registration code for Command & Conquer 3: Tiberium Wars comes with your copy — it's printed on the manual, the disc sleeve, or the card inside the case.
Codes are unique to each copy, so a key posted online by someone else won't validate for you. If you've lost yours and the game is tied to an EA account, their support team can sometimes recover it from your purchase history.