Should he sell Qualcomm stock before or after retiring?

For a married couple filing jointly in 2026, long-term capital gains are taxed at 0% until taxable income reaches $98,900, at 15% up to $613,700 and at 20% above that, plus 3.8% NIIT once MAGI passes $250,000. The same low-basis company shares can cost 23.8% in a working year and 0% in the first years after the paycheck stops.
Summary
Who: Minh, 60, an engineering director at Qualcomm in San Diego with 22 years of ESPP and RSU lots, married to Hanh, 58, a middle-school principal. Retiring in mid-2027. An illustrative composite; names and figures are hypothetical.
The problem: about $1.4 million of Qualcomm stock, roughly 45% of their investable assets, with about $950,000 of unrealized gain; a CPA whose default was to sell the oldest lots first, which would have put $300,000 of gain into a $450,000 wage year.
What Alphanso did: mapped every lot by basis and purchase date, sold the newest, highest-basis lots while he still worked, and scheduled the oldest, lowest-basis lots for the two gap years after retirement, when the 0% bracket and the NIIT threshold both open up.
The result: about $61,600 of federal tax on the oldest lots avoided in 2026 in favor of about $23,700 across 2028 and 2029, a concentration cut from 45% to about 35% before he retired, and a written calendar for the rest.
What did Minh hold when he set a retirement date?
Twenty-two years of a company's stock, bought six months at a time, and no plan for the order in which to let it go. Minh joined Qualcomm in 2004 as a modem engineer and now runs a team of sixty. He had done the patient things: every ESPP period since 2005, a maxed 401(k) with about $1.5 million in it, Hanh's pension on track, the Carmel Valley house paid off. Their CPA in Mission Valley files on time and had never given them a surprise. In the spring of 2026 Minh told his manager he would retire at the end of June 2027, and the question that had been easy to postpone became a dated one.
The Qualcomm position was about $1.4 million across roughly 50 lots. The oldest ESPP lots, bought in the 2000s through a plan that two advisory sources describe as a 15% discount with a 6-month lookback and a contribution cap of about 10% of base pay, had a cost basis near 20 cents on the dollar. The RSU lots from the last three years had a basis close to their current value, because RSUs are taxed as wages at vest and the vest-date value becomes the basis. Overall basis was about $450,000, so the embedded gain was about $950,000. The couple's 2026 household income was about $450,000, nearly all wages.
Why does the year of the sale matter as much as the decision to sell?
Because the capital gains rate is set by the income the gains stack on top of, and a retirement date changes that income. Long-term gains sit above ordinary income on the return; whatever portion of the total lands under $98,900 of joint taxable income in 2026 is taxed at 0%, the portion between $98,900 and $613,700 at 15%, and the rest at 20% (Rev. Proc. 2025-32). The 3.8% net investment income tax applies to the lesser of net investment income or the amount by which MAGI exceeds $250,000 for a joint return, a threshold set by statute and not adjusted for inflation (IRC Section 1411). In a $450,000 wage year, every dollar of gain is at 15% or 20% plus 3.8%. In a year with $60,000 of pension and interest, the first $71,100 of gain is at 0% and the NIIT does not start until the couple's total income passes $250,000.
$300,000 of long-term gain, married filing jointly, 2026 federal figures
Working year ($450,000 wages)
- Gain taxed at 0%: $0
- Gain taxed at 15%: $195,900
- Gain taxed at 20%: $104,100
- Capital gains tax: $50,200
- Net investment income tax: $11,400
- Federal tax on the gain: about $61,600
One gap year ($60,000 other income)
- Gain taxed at 0%: $71,100
- Gain taxed at 15%: $228,900
- Gain taxed at 20%: $0
- Capital gains tax: $34,300
- Net investment income tax: $4,200
- Federal tax on the gain: about $38,500
Two gap years ($150,000 of gain each, $60,000 other income)
- Gain taxed at 0%: $71,100 per year
- Gain taxed at 15%: $78,900 per year
- Gain taxed at 20%: $0
- Capital gains tax: $11,800 per year
- Net investment income tax: $0
- Federal tax on the gain: about $23,700 in total
The figures above treat 2028 and 2029 with 2026 numbers as a proxy, because the IRS publishes each year's thresholds in the autumn before it; the shape of the answer does not change when the numbers are indexed. State tax is extra. California taxes long-term gains as ordinary income at progressive rates, so a lower-income year lowers the state bill as well, though not to zero. This is how Alphanso frames a sell-or-hold decision: not whether the stock is good, but what each lot costs to turn into something else, and when.
What was the gap?
Nobody was choosing the lots, so the default was choosing them. Minh's CPA had suggested, reasonably, that he "start trimming" in 2026, and the brokerage's default cost-basis method for the account was first in, first out. Left alone, the first $300,000 of sales would have been the 2005 to 2009 ESPP lots, with roughly $300,000 of gain stacked on $450,000 of wages: about $61,600 of federal tax, before California. The CPA sees the return after the year ends. The brokerage sees the lots but not the retirement date. Hanh's pension office sees her start date. Nobody had the lot ledger, the retirement calendar and the bracket table on one page, and that is the whole gap. His CPA was right that he should trim. The order and the year were the missing pieces.
What did Alphanso change?
We split the decision into two questions: how much Qualcomm to hold, and which lots to sell in which year. The first was Minh's call. He is bullish on the company he spent his career at, and the plan does not argue with that; it sets a written rule for how much of the couple's retirement income can depend on one stock, and sells only what the rule requires. The second question is where the tax is, and it is the part a full-picture team does.
For 2026 and the first half of 2027, while wages are high, the rule sells the newest lots first: RSU shares vested in 2024 to 2026 with a basis close to their value. Selling $300,000 of those lots realizes about $40,000 of gain, for roughly $7,500 of federal tax including NIIT, and takes the position from 45% to about 35% of investable assets before the paycheck stops. That is the concentration cut, done in the expensive years at the cheapest possible price, by choosing lots instead of accepting the default.
The oldest lots wait for 2028 and 2029. In those years the household's other income is about $60,000, so each year holds $71,100 of 0% room and about $190,000 of headroom under the NIIT threshold. The calendar sells about $150,000 of gain from the 2005 to 2009 lots in each year: about $11,800 of federal tax per year, no NIIT, about $23,700 in total against the $61,600 the same shares would have cost in 2026. The window is real but it closes on its own: Social Security, taken at 67 or 70, and required minimum distributions, which begin at 75 for people born in 1960 or later, refill the low brackets, which is why the plan uses the early years rather than waiting for a better price.

Before: sell the oldest lots first, in 2026
- Lots sold in 2026: 2005 to 2009 ESPP, about $300,000 of gain
- Federal tax in 2026: about $61,600
- Lots sold in 2028 and 2029: none planned
- Federal tax in 2028 and 2029: $0
- Qualcomm as a share of investable assets by mid-2027: about 35%
- Total federal tax on the first $340,000 of gain: about $61,600 plus whatever the later sales cost
After: newest lots in 2026, oldest lots in 2028 and 2029
- Lots sold in 2026: 2024 to 2026 RSUs, about $40,000 of gain
- Federal tax in 2026: about $7,500
- Lots sold in 2028 and 2029: 2005 to 2009 ESPP, about $150,000 of gain each year
- Federal tax in 2028 and 2029: about $11,800 each year
- Qualcomm as a share of investable assets by mid-2027: about 35%
- Total federal tax on the first $340,000 of gain: about $31,100
Three things had to be solved alongside the calendar. ESPP lots carry their own tax rules: on a lot held long enough to qualify, part of the gain, the plan discount, is ordinary income rather than capital gain, so the lot plan counts that portion against the ordinary brackets, not the 0% room. The same gap-year room is also where a Roth conversion in a gap year would go, and the two compete for it; we modeled both and showed the couple what each dollar of conversion costs in lost 0% capital gains, and let them choose the mix. And because Minh is 60, the couple will buy marketplace health coverage until Medicare at 65, where the gains raise the income used to set premium tax credits; that was modeled year by year rather than discovered in April. Alphanso's AI agents track each lot's holding period and basis, and will flag the January after each gap-year sale to size the estimated payment, so the plan runs without anyone remembering it.
What did it save them?
- About $37,900 less federal tax on the same $300,000 of old-lot gain, from roughly $61,600 in a working year to roughly $23,700 across two gap years, by changing the year rather than the decision
- Qualcomm cut from 45% to about 35% of investable assets before retirement for roughly $7,500 of federal tax, by selling the newest, highest-basis lots first instead of the brokerage default
- A written lot calendar through 2029, with the Roth conversion and health coverage trade-offs priced in the same model instead of discovered later
- No argument about the stock, because the plan sized how much retirement income can rest on one company and left the rest to Minh
Why did this work?
The saving came from a lot ledger, a bracket table and a retirement date read together before the first trade, not from a view on the stock. The CPA, the brokerage and the pension office each had a correct piece. Alphanso's job was to put the pieces on one page, show the couple what each lot would cost in each year, and then do the work: the lot elections, the calendar, the estimates. The sequence-of-returns side of the same decision, how much of the first years of spending should sit outside the stock at all, is the companion question, and it was answered in the same model.
Alphanso Inc is a flat-fee fiduciary wealth advisory for employees with equity compensation (RSUs, ISOs, NSOs and ESPP); advisors are paid a flat annual fee, never a percentage of assets or commissions. The flat annual fee is the same whether a client sells every share or none, which is what makes it possible to lay out the lot calendar and let the client decide. If retirement is inside three years and one company's stock is a large share of what you own, book a call and we will map your lots against your own gap years.
FAQ
Is it better to sell appreciated company stock before or after I retire?
For most people the gains cost less in the first years after the paycheck stops, because long-term gains are taxed at 0% up to $98,900 of joint taxable income in 2026 and the 3.8% NIIT does not apply until MAGI passes $250,000. The trade-off is that holding the shares until then keeps the concentration risk on the table. A common answer is to sell high-basis lots while working and save low-basis lots for the gap years.
How do the gap years before Social Security and RMDs work for capital gains?
Between the last paycheck and the start of Social Security and required minimum distributions, a household's ordinary income is often low, so more of each year's long-term gain lands in the 0% and 15% brackets. The room is per year, so spreading a large sale over two or three gap years usually costs less than taking it in one. Once Social Security and RMDs begin, the low brackets fill up again.
Does selling stock in retirement trigger the 3.8% net investment income tax?
Only if modified adjusted gross income, including the gain itself, exceeds $250,000 for a joint return or $200,000 for a single filer. Those thresholds are set by statute and do not rise with inflation. A retiree with $60,000 of other income can realize up to about $190,000 of gain in a year before the tax applies, which is one reason to spread sales across years.
Which lots of company stock should I sell first before retiring?
In high-income years, lots with a cost basis close to today's value, usually recent RSU vests, realize the least gain per dollar sold and cut concentration cheaply. Lots with a very low basis, such as old ESPP purchases, realize the most gain and are the ones worth saving for low-income years. Choosing lots requires selecting specific identification at the brokerage before the sale, because the default is often first in, first out.
Does a Roth conversion compete with 0% capital gains in the same year?
Yes. Both use the same low-bracket room: a Roth conversion adds ordinary income, which pushes long-term gains up into the 15% bracket, and gains add to MAGI, which can push the conversion into a higher bracket. Most plans split the gap years between the two rather than doing both at full size in one year.
Priyanshi Gupta is Head of Product at Alphanso; she was one of the first product managers at Datadog and led its APM team through the company's IPO.
This case study is a composite illustration based on real Alphanso client scenarios. Names and identifying details have been changed for privacy. Results are not guaranteed and will vary based on individual circumstances. All investing involves risk, including the possible loss of principal. Tax services are for educational purposes and do not constitute legal advice. Alphanso Inc is a registered investment adviser; registration does not imply a certain level of skill.





