Capital Gains When Selling a House

How capital gains work when selling a house in Virginia, the Section 121 exclusion homeowners can use, and what changes once a home has been rented out.

Most Virginia homeowners selling a primary residence never owe a dollar of federal capital gains tax, not because home sales are untaxed but because the Section 121 exclusion shelters up to $250,000 of gain for a single filer and $500,000 for a married couple filing jointly, provided the ownership and use tests are met. The exclusion is generous enough that it covers the entire gain for most sales in Virginia's mid-sized metros, though it stops being a complete answer once appreciation runs high or the property was ever used as a rental.

The Two-of-Five-Years Test

To qualify, the seller needs to have owned and used the property as a primary residence for at least two of the five years before the sale, and those two years do not need to be continuous. A Williamsburg homeowner who lived in a house for eighteen months, rented it out for two years while working elsewhere, then moved back for another year before selling can still meet the test, since the total qualifying use adds to more than two years within the five-year window.

When Appreciation Exceeds the Exclusion

Northern Virginia's appreciation over the past decade has pushed some long-held homes well past the exclusion ceiling. A couple who bought a house in Arlington for $420,000 in 2011 and sells today for $1.1 million has roughly $680,000 of gain against a $500,000 joint exclusion, leaving about $180,000 exposed to standard federal capital gains rates and Virginia's income tax on top of it. Homeowners in this position sometimes look at documenting every eligible capital improvement made over the years, from a kitchen remodel to an addition, since each one raises basis and reduces the taxable overage.

What Changes If the Home Was Ever Rented

A house that spent time as a rental before being sold loses part of its exclusion eligibility for the years it was used as a rental, under the nonqualified use rules, and any depreciation claimed during the rental period is generally recaptured regardless of how the rest of the gain is treated. A Fredericksburg owner who rented a home for two years before moving back in and eventually selling needs to allocate gain between qualified and nonqualified use periods, a calculation most sellers do not attempt without a tax preparer's help.

Options Once the Exclusion Runs Out

For the portion of gain that exceeds the exclusion, or for a home that never qualified as a primary residence in the first place, the remaining strategies look more like the investment-property playbook than the homeowner one. A partial installment sale, timing the closing around a lower-income year, or converting the property to rental use and later exchanging it under a 1031 exchange are the realistic paths, each with its own tradeoffs and its own IRS documentation requirements.

Frequently Asked Questions

Do you have to reinvest the proceeds from selling your Virginia home to avoid capital gains?

No, not for a primary residence. The Section 121 exclusion applies regardless of what the seller does with the proceeds, which is different from investment property rules where deferral tools like a 1031 exchange do require reinvesting into a replacement property.

Can you use the Section 121 exclusion more than once?

Yes, but generally not more than once every two years, since the exclusion applies to a sale only if the seller has not excluded gain on another home sale within the two years before the current sale.

What happens if your Virginia home was inherited rather than purchased?

An inherited home generally receives a stepped-up basis to its fair market value on the date of the prior owner's death, which often eliminates most or all of the gain that would otherwise be measured from the original purchase price decades earlier.

Does a home office deduction affect the exclusion when you sell?

A home office claimed as a simple percentage deduction within the same dwelling generally does not disqualify the exclusion, but any separate depreciation taken on a distinct home-office space is typically recaptured, similar to a rental property, even on an otherwise qualifying primary residence.

Is the exclusion different for a Virginia couple who is not married?

Yes. Each unmarried co-owner can potentially claim up to $250,000 individually if both meet the ownership and use tests on their share, which can add up to more total exclusion than a married couple's combined $500,000 in some ownership structures, though the details depend on how title is held.

Ready to model the tax impact?

Share your sale details and open questions for your Virginia exchange.

Start Exchange Review