I asked Cinda Jones, a Certified Divorce Financial Analyst (CDFA) and owner of Divorce Financial Solutions, to help me answer this complicated question. Please note that these answers are general in nature. For answers to any specific questions, it is always wise to consult an attorney in your state. Retirement Assets (401k's, IRA's, 403b's, etc): Contributions and benefit accrual during marriage are community property and will be divided in the settlement agreement upon divorce. Even if only one spouse is contributing to a plan during marriage, the other spouse is still entitled to half of the value accumulated during the marriage.
Non-Retirement Assets (Brokerage Accounts, Individual Stocks, etc.): Cinda recommends keeping these separate and keeping all records. She says to never throw away mortgage purchase or refi documents, bank statements, investment statements and tax returns. During a divorce, the burden of proof falls to the person who wants to make a separate claim or ask for reimbursement. Surprisingly (at least to me in this digital age), she has found it may be impossible to obtain historical records from financial institutions or even the IRS.
Other situations I see fairly frequently: Gifting from parents to help with a house down payment, an inheritance used to help remodel the joint home and rental properties or businesses that were established before marriage. Cinda cautions that it is very hard to generalize in these situations and the rules may vary by state. Regardless, even if there is a valid separate property claim, the burden of proof falls on the person making the claim so you need to have supporting documents.