State tax filing

What is the rule for the capital gain exclusion of $500K (2 people) if I sell my principal residence in NJ in the future - after I become a Florida resident?  I'm considering becoming a Florida resident because I spend 7 months in Florida and I wouldn't have to pay any NJ income tax. I've been in my NJ home for almost 50 years and I don't have receipts of all the improvements that I've made.

 

Thanks for your help.