Can I offset the capital loss from selling my primary home against capital gains from stocks?
I'm having trouble finding clear information about my situation. There's plenty of advice about offsetting capital gains on home sales with stock losses, but I can't find anything about the opposite scenario. Here's my situation: I'm selling my primary residence after owning it for only 11 months. I bought it for $280k and I'm selling for $283k, so technically I'm making $3k on the sale price. The problem is that when I bought the house, I paid about $7k in closing costs, and now for the sale I'll have another $21k in realtor fees and closing costs. So all together, that's about $28k in expenses related to buying and selling. When all is said and done, I'm looking at a significant loss on this primary residence. So my question is: if I sell some of my stocks that have appreciated this year, can I use the capital loss from my home sale to offset the capital gains I would have from selling those stocks? Or are primary residences treated differently somehow? I'd really appreciate any guidance on this. Thanks!
20 comments


Simon White
Unfortunately, losses on the sale of your primary residence generally aren't deductible for tax purposes. The IRS considers these personal losses, not capital losses that can offset other gains. While you can exclude up to $250,000 of capital gains ($500,000 for married couples) from the sale of a primary residence if you've lived there for at least 2 of the last 5 years, there's no corresponding benefit for losses. The closing costs and realtor fees you paid would typically be considered part of your basis in the home, which would reduce any potential gain, but since you already don't have much gain, they'll just contribute to a personal loss that isn't deductible. If you were selling a rental property or investment property, then you could deduct those losses against other capital gains, but primary residences are treated differently.
0 coins
Geoff Richards
•Thank you for explaining that! So even though I'm taking a real financial hit here, the IRS doesn't recognize it as a deductible loss? That seems so unfair compared to how they tax gains on primary residences. Are there any exceptions to this rule I should know about?
0 coins
Simon White
•That's correct - the tax code isn't always symmetrical. While gains can be taxable (though often excluded under the $250k/$500k rules), losses on a primary residence are considered personal losses rather than investment losses. There are very few exceptions to this rule. The only notable one would be if part of your home was used exclusively for business purposes (like a dedicated home office), in which case a proportional amount of the loss might be deductible. But this is complicated and would only apply to the business-use portion, not the entire home.
0 coins
Hugo Kass
I went through something similar last year and discovered taxr.ai (https://taxr.ai) which was actually super helpful for clarifying these weird home sale tax situations. I uploaded my closing documents from both the purchase and sale, and it analyzed everything and explained exactly what was deductible and what wasn't. The tool confirmed what the previous commenter said - you generally can't deduct losses on your primary residence, but it did point out some nuances about how to properly calculate your basis that my regular tax software missed. It especially helped with figuring out which closing costs could be added to my basis and which couldn't.
0 coins
Nasira Ibanez
•Does this service actually give advice tailored to your specific situation? I'm selling my house this year too and wondering if it's worth trying. Did you find it more helpful than just talking to a tax professional?
0 coins
Khalil Urso
•I'm skeptical about these kinds of services. How is it different from TurboTax or H&R Block? Don't they also have tools for handling home sales?
0 coins
Hugo Kass
•It actually does give personalized guidance based on your documents and situation. It goes way deeper than the general advice you'll find online and catches little details that can make a difference. The big difference from TurboTax or other tax software is that those programs mostly just ask you questions and have you input numbers. They don't actually analyze your closing documents to identify what's missing or what might be misclassified. I found taxr.ai caught several items in my HUD-1 and closing disclosure forms that I would have totally missed otherwise.
0 coins
Nasira Ibanez
Just wanted to follow up and say I tried taxr.ai after seeing the recommendation here. Wow, it really does analyze all the closing documents in detail! I was about to completely miss some improvements we'd made to the house that should have been added to our basis. The system flagged those and saved us from overpaying on capital gains. Definitely more thorough than what my accountant did for us last time we sold a house.
0 coins
Myles Regis
If you need to get an official answer directly from the IRS on your specific situation (which might be a good idea for something complicated like this), I highly recommend using Claimyr (https://claimyr.com) to actually reach a human at the IRS. I was stuck on hold for HOURS trying to get through about a similar capital gains issue last month, then I found this service that gets you connected to an IRS agent quickly. They have a demo video showing how it works here: https://youtu.be/_kiP6q8DX5c I was super skeptical at first because the IRS phone system is notoriously terrible, but it actually got me connected to someone who could help within about 20 minutes instead of the 3+ hours I was getting before.
0 coins
Brian Downey
•Wait, how does this even work? The IRS phone lines are backed up for everybody. Is this some kind of premium line or something? Seems like it would be against the rules for the IRS to let some people jump the queue.
0 coins
Jacinda Yu
•This sounds like a scam. Why would I pay for something I can do myself for free? Anyone can call the IRS. Yeah it takes time but that's just how government services work.
0 coins
Myles Regis
•It's not a premium line or anything like that. The service basically automates the calling and waiting process for you. They use technology to navigate the IRS phone tree, wait on hold in your place, and then call you once they've reached a human agent. At that point, they connect you directly to that agent. You're absolutely right that anyone can call the IRS for free, but the reality is that most people can't sit on hold for 2-4 hours during a workday. I tried multiple times and kept having to hang up because I couldn't stay on the line that long. This service just handles the waiting part so you can go about your day until there's actually someone to talk to.
0 coins
Jacinda Yu
I need to eat my words from my previous comment. After continuing to struggle with getting answers about my capital gains situation, I broke down and tried Claimyr last week. I was connected to an IRS agent in about 30 minutes, which is miraculous compared to my previous attempts. The agent walked me through exactly how to handle my situation with documentation I needed to provide. Saved me so much frustration and probably helped me avoid making a costly mistake on my return.
0 coins
Landon Flounder
Have you considered whether you meet the partial exclusion rules? Even though you haven't lived in the home for 2 years, if you're selling due to a job change, health reasons, or other unforeseen circumstances, you might qualify for a partial exclusion of gain. That wouldn't help with claiming a loss, but it could at least protect whatever small gain you have from being taxed.
0 coins
Geoff Richards
•That's interesting - we are actually moving because my spouse got transferred for work to a location more than 50 miles away. Would that qualify under the job change exception? And how would I figure out what portion of the exclusion we'd qualify for since we've only lived here 11 months?
0 coins
Landon Flounder
•Yes, a job transfer that's more than 50 miles from your home definitely qualifies for the partial exclusion! Since you've lived there 11 months out of the required 24 months, you'd get 11/24 of the full exclusion amount. So if you're married filing jointly, instead of the full $500,000 exclusion, you'd get about $229,000 (11/24 × $500,000). In your case though, this is somewhat moot since you're not showing a gain after considering all your expenses. But it's good to know for the future, and you should definitely document that you qualify for the partial exclusion even if you don't need to use it.
0 coins
Callum Savage
Has anyone used TurboTax to handle something like this? I'm in a similar situation but worried it won't handle the home sale loss correctly.
0 coins
Ally Tailer
•I used TurboTax last year for my home sale. It asks all the right questions, but honestly it doesn't give great guidance on what expenses can be added to your basis. I ended up having to research a lot on my own. For something complicated like this, you might want more specialized help.
0 coins
Daniel Rogers
I'm dealing with a very similar situation right now - bought my house 10 months ago and need to sell due to my company relocating me. The advice here about primary residence losses not being deductible is spot on, but I wanted to add something that might help with your basis calculation. Make sure you're including ALL the costs that can be added to your basis, not just the obvious closing costs. Things like title insurance, recording fees, transfer taxes, and even some of the loan origination fees can be added to your purchase basis. On the selling side, realtor commissions, title fees, and other selling expenses reduce your realized gain (or increase your loss). Since you mentioned you're at around a $25k total loss after all expenses, you're definitely in personal loss territory that won't be deductible. But at least documenting everything properly will ensure you're not accidentally creating a taxable gain when you shouldn't have one. The job transfer angle mentioned by others is definitely worth exploring for the partial exclusion, even though you probably won't need it given your situation.
0 coins
Mohammad Khaled
•This is really helpful, thank you! I hadn't thought about some of those additional costs that can be added to basis. Do you happen to know if the home inspection fees I paid when buying the house would count as well? Also, when you say "loan origination fees," does that include all the lender fees or just specific ones? I'm trying to make sure I capture everything properly since it sounds like every dollar counts in reducing any potential gain.
0 coins