Do You Have to Pay Capital Gains When Selling a Home in Pennsylvania?
You only owe capital gains tax when selling a Pennsylvania home if you actually have taxable profit after exemptions and your personal situation is considered, and many Montgomery County homeowners pay little or nothing at the federal level if they qualify for the primary residence exclusion. Pennsylvania, however, still taxes most capital gains at a flat 3.07 percent even when the federal gain is excluded.
What Capital Gains Tax Is (Basic Formula)
Capital gains tax is charged on your profit from selling an asset.
For a home, the basic calculation is:
Sale price
minusAdjusted cost basis (what you paid plus certain closing costs and documented improvements)
equalsCapital gain.
Your basis can include:
Original purchase price.
Certain closing costs when you bought.
Capital improvements (new roof, additions, major remodels—not routine maintenance).
Getting your basis right matters because a higher basis means a lower taxable gain.
Federal Primary Residence Exclusion (2‑of‑5 Rule)
If the home is your primary residence, federal tax law often lets you exclude a large portion of your gain.
In 2026, the standard Section 121 rules are:
Up to 250,000 dollars of gain excluded for single filers.
Up to 500,000 dollars of gain excluded for married couples filing jointly.
To qualify, you generally must:
Have owned the home for at least 2 of the last 5 years before the sale.
Have lived in it as your main home for at least 2 of the last 5 years (the 24 months don’t need to be consecutive).
Not have used this exclusion on another home sale in the last 2 years.
If your total gain is under the limit and you meet these tests, you may owe no federal capital gains tax on that sale.
Example: Simple Primary Residence Sale
You bought your home for 300,000 dollars.
You sell it for 550,000 dollars.
Ignoring improvements for simplicity, your gain is about 250,000 dollars.
If you qualify for the full 250,000‑dollar exclusion as a single seller, or 500,000‑dollar exclusion as a married couple filing jointly, that gain can be fully excluded from your federal taxable income.
But you still need to consider state tax (see below), your true adjusted basis (with improvements), and your overall income picture with your CPA.
When Capital Gains Tax Is More Likely
You may have taxable capital gains if:
The property is a rental, second home, or investment (not your primary residence).
You don’t meet the 2‑of‑5‑year ownership/use tests (for example, you moved out more than 3 years ago and never moved back).
Your gain exceeds the 250,000‑dollar / 500,000‑dollar exclusion.
You’ve used the exclusion on another sale in the last 2 years.
For rentals or investment property:
You may also face depreciation recapture, where prior depreciation deductions are taxed back at sale.
In these situations, federal long‑term capital gains rates (0%, 15%, or 20% depending on income) can apply.
Inherited Homes and Stepped-Up Basis
Inherited properties typically receive a stepped‑up basis:
The tax basis usually resets to the property’s fair market value at the date of death (or alternate valuation date, if used).
If you sell relatively soon after inheriting at roughly that value, taxable capital gain may be small or zero.
If you hold it for years and the property appreciates, capital gains are based on the increase after inheritance.
Pennsylvania also imposes inheritance tax on the transfer itself (separate from capital gains), with rates depending on your relationship to the decedent.
Inherited homes are a prime case for talking to both your estate attorney and CPA before choosing whether and when to sell.
How Pennsylvania Taxes Gains (State Level)
Pennsylvania treats capital gains differently from the federal system:
PA taxes most capital gains as ordinary income at a flat 3.07 percent rate.
The state does not distinguish between short‑term and long‑term gains.
PA does not offer a home sale exclusion like the federal 250,000‑dollar / 500,000‑dollar primary residence exclusion.
So even if you owe zero federal capital gains tax thanks to the primary residence exclusion, you may still owe Pennsylvania income tax on your gain.
Because PA’s rules are relatively simple but unforgiving (no lower long‑term rate and no home-sale exclusion), many homeowners benefit from planning and accurate basis tracking.
Ways to Reduce or Plan for Capital Gains
Helpful strategies to discuss with your tax advisor include:
Confirming you meet the 2‑of‑5‑year ownership and occupancy rules to use the federal exclusion.
Keeping detailed records of capital improvements and certain closing costs to boost your basis and reduce gain.
Reviewing your prior use of the property (primary residence vs rental) and any depreciation taken.
Considering timing—such as which tax year the sale falls in, and whether to coordinate with other income or deductions.
Online calculators can model approximate tax impact, but your CPA can tailor this to your full income picture and future plans.
Want to See What Your Potential Profit Might Look Like?
First, estimate your likely sale price in today’s Montgomery County market.
👉 Get Your Instant Home Value Here
👉 Then schedule a seller consultation
You can review:
Estimated sale price and net proceeds.
Whether you likely fit the primary residence exclusion.
How improvements and costs affect your basis.
A plan to coordinate your sale timing with your CPA for both federal and Pennsylvania taxes.

