Just to clarify though, if you are divorced you need to have been married ten years to collect social security benefits based on your ex. But if you're married there's no formal time requirement.