How LLC Owners Save on Taxes in 2026

Business Owner Find more write-offs — search your profession or a specific deduction
Try:
Others Also Use These Strategies
Business IRC §199A 2026 Law Update

Qualified Business Income (QBI) Deduction

Pass-through business owners (sole props, partnerships, S-Corps, LLCs) can deduct up to 23% of qualified business income starting in 2026, permanently under the OBBBA. The deduction reduces effective tax rates significantly.

Eligibility Requirements
  • Income from a pass-through entity or sole proprietorship
  • Taxable income below income thresholds for full deduction (consult advisor for 2026 inflation-adjusted limits)
  • Specified service trades may be phased out above thresholds
  • New minimum deduction of $400 for taxpayers with at least $1,000 of active QBI
Example Savings Scenario

A consultant earning $200,000 in QBI deducts $46,000 (23%), saving $17,020 at a 37% rate — $2,220 more than under the old 20% rule.

MERNA Strategy Notes

The OBBBA (July 4, 2025) permanently extended and increased the QBI deduction from 20% to 23% starting in 2026. W-2 wage and property limitations still apply above income thresholds. Restructuring into an S-Corp can maximize the W-2 wage limitation.

Common Mistake: Specified service businesses (law, health, consulting) phase out above income thresholds.
UNK Client Win Small Business Owner / Sole Proprietor

How a Denver Plumber Claimed a $36,000 QBI Deduction He Didn't Know Existed

A UNK client ran a plumbing business generating $180,000 in net income. His previous tax preparer had never mentioned the QBI deduction. Uncle Kam identified that he qualified for the full 23% deduction under the OBBBA — $41,400 off his taxable income. At his 22% marginal rate, this saved $9,108 in federal taxes. The deduction is now permanent, so the client is working with Uncle Kam to stack it with retirement contributions and S-Corp election for maximum benefit.

Result: $9,108 in annual federal tax savings through a deduction the client had been missing for years.

Own a pass-through business? The QBI deduction is now 23% and permanent. Book a call to confirm you're capturing the full amount.

Be the Next Win — Book a Call
Common Questions About Qualified Business Income (QBI) Deduction
Business IRC §1366, Rev. Rul. 74-44

S-Corp Reasonable Salary Optimization

S-Corp shareholders pay payroll taxes only on their "reasonable salary," not on all business profits. Distributions above the salary avoid 15.3% self-employment tax.

Eligibility Requirements
  • Operate as an S-Corporation
  • Pay yourself a reasonable salary for services rendered
  • Take remaining profits as distributions
Example Savings Scenario

A business earning $300,000 net. Salary set at $80,000 (reasonable). Distributions: $220,000. SE tax savings: $220,000 × 15.3% = $33,660/year.

MERNA Strategy Notes

The IRS defines "reasonable" based on industry, duties, and comparable salaries. Too low a salary is the #1 S-Corp audit trigger. Document your salary rationale.

Common Mistake: Setting salary at $0 or unreasonably low is the #1 S-Corp audit trigger.
UNK Client Win Freelancer / Consultant / S-Corp Owner

How an Atlanta Consultant Saved $18,400/Year by Optimizing Her S-Corp Salary

A UNK client was running her marketing consulting business as a sole proprietor, paying self-employment tax on her full $180,000 net income — a $25,434 SE tax bill every year. Uncle Kam helped her elect S-Corp status and set a reasonable salary of $72,000. The remaining $108,000 was taken as a distribution, exempt from self-employment tax. The SE tax on $72,000 was $10,188 — saving $15,246/year. After accounting for S-Corp administrative costs of $2,500, the net annual savings was $12,746.

Result: $12,746 in annual tax savings. Over 5 years, that is $63,730 in savings — enough to fund a Solo 401(k) and build real retirement wealth.

If you earn over $50,000 as a freelancer or consultant, an S-Corp election could save you $10,000–$30,000/year. Book a call to run your numbers.

Be the Next Win — Book a Call
Common Questions About S-Corp Reasonable Salary Optimization
Business IRC §179

Section 179 Expensing

Immediately expense the full cost of qualifying business equipment, software, and certain vehicles in the year of purchase instead of depreciating over multiple years.

Eligibility Requirements
  • Business equipment, machinery, or software
  • Property placed in service during the tax year
  • Business income must be sufficient (cannot create a loss with §179)
Example Savings Scenario

Purchasing $500,000 in equipment. Full §179 deduction saves $185,000 in taxes at a 37% rate in Year 1 vs. spreading over 5–7 years.

MERNA Strategy Notes

Combine with bonus depreciation for any amount above the §179 limit. Heavy SUVs are capped at $30,500 under §179 but can use bonus depreciation for the remainder.

Common Mistake: Section 179 cannot create a net operating loss — bonus depreciation can.
UNK Client Win Medical/Dental Practice Owner

How a Miami Dentist Wrote Off $185,000 in Equipment in Year One

A UNK client opened a new dental practice and purchased $185,000 in dental chairs, X-ray equipment, and computer systems. Instead of depreciating the equipment over 5–7 years, Uncle Kam applied Section 179 to expense the full $185,000 in Year 1. At the client's 37% marginal rate, this generated $68,450 in immediate tax savings — essentially the IRS subsidizing 37% of his equipment purchase.

Result: $68,450 in Year 1 tax savings. The client used the tax savings to fund his first Solo 401(k) contribution, building retirement wealth while reducing his tax bill further.

Buying equipment, vehicles, or technology for your business? Section 179 could let you write it all off in Year 1. Book a call to plan your purchase timing.

Be the Next Win — Book a Call
Common Questions About Section 179 Expensing
Business IRC §3134

Employee Retention Credit (ERC)

A refundable payroll tax credit for businesses that retained employees during COVID-19 disruptions. Up to $5,000 per employee in 2020 and $21,000 per employee in 2021.

Eligibility Requirements
  • Had W-2 employees in 2020 or 2021
  • Experienced a significant decline in gross receipts OR government-ordered partial/full shutdown
  • Did not receive PPP loan forgiveness for the same wages (amended claims possible)
Example Savings Scenario

A restaurant with 20 employees that experienced a 50% revenue decline in Q2 2020 qualifies for up to $100,000 in ERC refunds for that quarter alone.

MERNA Strategy Notes

Amended returns (Form 941-X) can be filed for 2020 and 2021. IRS moratorium on new claims lifted — work with a qualified ERC specialist, not a mill.

Common Mistake: IRS is aggressively auditing improper ERC claims — only claim with proper documentation and a qualified advisor.
UNK Client Win Small Business Owner

How a Restaurant Owner Claimed $180,000 in Employee Retention Credits

A UNK client owned a restaurant that had been significantly impacted by COVID-19 capacity restrictions in 2020 and 2021. He had not claimed the Employee Retention Credit because he had also received a PPP loan and assumed he was ineligible. Uncle Kam corrected this misconception: after the Consolidated Appropriations Act of 2021, businesses could claim both PPP forgiveness and the ERC — just not on the same wages. The client qualified for $180,000 in ERC across 2020 and 2021 based on the revenue decline test and the government-mandated capacity restrictions.

Result: $180,000 in refundable payroll tax credits recovered through amended payroll tax returns. The client received the refund as a check from the IRS.

Business impacted by COVID in 2020 or 2021? The ERC filing window is still open for some periods. Book a call immediately to evaluate your eligibility.

Be the Next Win — Book a Call
Common Questions About Employee Retention Credit (ERC)
Business IRC §280A(g)

Augusta Rule (Section 280A Home Rental)

Under IRC §280A(g), a homeowner can rent their personal residence to their business for up to 14 days per year. The rental income is completely tax-free to the homeowner, and the business deducts the full rental payment.

Eligibility Requirements
  • Own a business (S-Corp, C-Corp, or partnership)
  • Own your personal residence
  • Have legitimate business meetings, retreats, or events at your home
Example Savings Scenario

A business owner renting their home to their S-Corp for 14 days at $2,000/day: $28,000 in tax-free income to the owner + $28,000 business deduction saves $10,360 at a 37% rate.

MERNA Strategy Notes

Must charge a fair market rate (get a comparable venue quote). Document the business purpose of each meeting. The 14-day limit is strict — do not exceed it.

Common Mistake: Charging above fair market value or lacking documentation of business purpose are major audit triggers.
UNK Client Win Business Owner / S-Corp

How a Business Owner Paid His Company $14,000 to Use His Home and Deducted Every Dollar

A UNK client owned an S-Corp and held quarterly board meetings and annual planning retreats. Uncle Kam implemented the Augusta Rule (IRC Section 280A(g)): the client rented his personal home to his S-Corp for 14 days per year at a fair market rental rate of $1,000/day — $14,000 total. The S-Corp deducted the $14,000 as a business expense. The client received the $14,000 as rental income that is completely tax-free under the 14-day rule. Net result: $14,000 moved from the S-Corp (taxable) to the client (tax-free), saving $5,180 in federal taxes at the 37% rate.

Result: $5,180 in annual federal tax savings. The strategy is 100% legal, requires minimal paperwork, and can be repeated every year.

Own a business and a home? The Augusta Rule is one of the simplest legal tax strategies available. Book a call to implement it this year.

Be the Next Win — Book a Call
Common Questions About Augusta Rule (Section 280A Home Rental)
Business IRC §199A

QBI Deduction — Section 199A (20% Pass-Through Deduction)

Pass-through business owners (sole props, S-Corps, LLCs, partnerships) can deduct up to 20% of qualified business income from taxable income. This is one of the largest tax breaks available to small business owners.

Eligibility Requirements
  • Own a pass-through business
  • Taxable income under $197,300 (single) or $394,600 (married) for full deduction
  • Specified service businesses (law, consulting, finance) phase out above these thresholds
Example Savings Scenario

A business owner with $200,000 in QBI at a 24% rate: 20% deduction = $40,000 reduction in taxable income = $9,600 in tax savings.

MERNA Strategy Notes

Set to expire after 2025 — Congress may extend. Maximize by keeping income below phase-out thresholds. W-2 wage limitation applies above thresholds.

Common Mistake: Specified service trades (law, consulting, financial services) lose the deduction above income thresholds.
UNK Client Win Freelancer / Self-Employed

How a Consultant Claimed a $42,000 QBI Deduction and Paid Tax on Only 80% of His Income

A UNK client earned $210,000 as an independent management consultant. He had heard of the QBI deduction but assumed his consulting work was a "specified service trade or business" (SSTB) that disqualified him. Uncle Kam analyzed the facts: management consulting is not on the IRS's SSTB list (which includes law, health, financial services, and performing arts — but not general consulting). Under the OBBBA, the client qualified for the full 23% QBI deduction: 23% x $210,000 = $48,300. At his 37% marginal rate, this saved $17,871 in federal taxes.

Result: $17,871 in annual federal tax savings through a deduction the client almost missed. Uncle Kam also implemented S-Corp election and retirement contributions to further reduce taxable income.

Self-employed or own a pass-through business? The QBI deduction could reduce your taxable income by 23% in 2026. Book a call to confirm you're capturing it.

Be the Next Win — Book a Call
Common Questions About QBI Deduction — Section 199A (20% Pass-Through Deduction)
Business IRC §162, §179 Uncle Kam Clients Only

Vehicle & Mileage Deduction

Deduct business vehicle expenses using the standard mileage rate or actual expenses (depreciation, gas, insurance, repairs). Section 179 and 100% bonus depreciation allow full expensing of heavy SUVs and trucks in Year 1.

Eligibility Requirements
  • Vehicle used for business purposes
  • Mileage log maintained for standard rate method
  • Heavy SUV (6,000+ lbs GVWR) for Section 179 bonus
Example Savings Scenario

Driving 20,000 business miles at 72.5¢/mile = $14,500 deduction. A $80,000 SUV over 6,000 lbs can be fully expensed under 100% bonus depreciation, saving $29,600 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §45E Uncle Kam Clients Only

Retirement Plan Startup Tax Credit

Small businesses with 100 or fewer employees receive a tax credit of up to $5,000 per year for 3 years for the costs of starting a new retirement plan, plus an additional credit for employer contributions.

Eligibility Requirements
  • 100 or fewer employees earning at least $5,000
  • No retirement plan in the prior 3 years
  • At least one non-highly compensated employee participates
Example Savings Scenario

A 10-person company starting a 401(k) receives $5,000/year for 3 years = $15,000 in direct tax credits, covering most of the setup and administration costs.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business Structure IRC §1362, §11 Uncle Kam Clients Only

LLC Tax Election Strategy (S-Corp vs. C-Corp vs. Sole Prop)

LLCs are tax-neutral entities — the tax election determines how income is taxed. S-Corp election saves self-employment taxes; C-Corp election enables retained earnings at 21% rate.

Eligibility Requirements
  • Own an LLC
  • Net profit over $40,000/year for S-Corp consideration
  • Net profit over $100,000/year for C-Corp consideration
Example Savings Scenario

An LLC earning $200,000 net profit: default taxation costs $28,240 in SE tax. S-Corp election with $80,000 salary saves $12,000+/year in SE taxes.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §105, §9831 Uncle Kam Clients Only

Section 105 HRA / QSEHRA Health Reimbursement

Qualified Small Employer Health Reimbursement Arrangements (QSEHRAs) allow small businesses to reimburse employees for individual health insurance premiums and medical expenses tax-free.

Eligibility Requirements
  • Fewer than 50 full-time employees
  • No group health plan offered
  • Employees have individual health insurance coverage
Example Savings Scenario

A business owner reimbursing 5 employees $500/month each: $30,000 in annual reimbursements are fully deductible, saving $11,100 at a 37% rate vs. paying after-tax.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §199A Uncle Kam Clients Only

LLC Owner QBI Deduction (20% Pass-Through Deduction)

LLC owners who are pass-through entities can deduct up to 20% of qualified business income (QBI) under Section 199A — worth $10,000–$40,000 per year for profitable LLCs. The deduction phases out for specified service businesses above income thresholds. LLC owners with W-2 employees or significant property can maximize the deduction above the threshold using wage and property limitations.

Eligibility Requirements
  • Must have qualified business income from a pass-through entity (LLC, sole prop, S-Corp, partnership)
  • Deduction is 20% of qualified business income (QBI)
  • Income limits apply: $191,950 (single) or $383,900 (married) in 2024
  • Specified service trades (law, accounting, health, financial services) have additional limits
Example Savings Scenario

An LLC owner with $100,000 in QBI deducts $20,000 (20% of $100,000) on Form 1040, saving $7,400 at 37% - without any additional spending required.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §73, §3121 Uncle Kam Clients Only

Hire Your Children in the Business

A sole proprietor or single-member LLC can hire their children under 18 and pay them wages up to the standard deduction amount ($14,600 in 2025) — the child pays no income tax and the business deducts the full amount.

Eligibility Requirements
  • Own a sole proprietorship or single-member LLC (not S-Corp for FICA exemption)
  • Children under 18 performing legitimate work
  • Paying reasonable wages for actual services rendered
Example Savings Scenario

A business owner in the 37% bracket paying two children $14,600 each: $29,200 in deductions saves $10,804 in federal taxes. Children owe $0 in income tax.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Bookkeeper Home Office & Vehicle Deduction

Bookkeepers working from home can deduct the home office space used exclusively for client work — typically worth $1,500–$4,000 per year using the actual expense method. Vehicle mileage to client offices, bank runs, and networking events is deductible at 70 cents per mile. A bookkeeper driving 5,000 business miles deducts $3,500.

Eligibility Requirements
  • Must use a dedicated space in your home exclusively and regularly for bookkeeping
  • Vehicle must be used for business purposes (client meetings, bank runs)
  • Must report income on Schedule C
  • Must have documentation of business use
Example Savings Scenario

A freelance bookkeeper using 12% of their home for bookkeeping deducts $2,400/year in home office expenses, plus $2,010 in vehicle mileage (3,000 miles x $0.67), saving $1,633 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Home Office Deduction

Deduct a portion of your home expenses (mortgage interest, rent, utilities, insurance, depreciation) based on the percentage of your home used exclusively and regularly for business.

Eligibility Requirements
  • Self-employed, freelancer, or business owner
  • Space used exclusively and regularly for business
  • Principal place of business or where clients are met
Example Savings Scenario

A 200 sq ft office in a 2,000 sq ft home = 10% allocation. $30,000 in home expenses × 10% = $3,000 deduction, saving $1,110 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §168(k) Uncle Kam Clients Only 2026 Law Update

Bonus Depreciation

Deduct 100% of the cost of qualifying new or used property in the first year it is placed in service. The OBBBA permanently restored 100% bonus depreciation for property with a recovery period of 20 years or less.

Eligibility Requirements
  • New or used qualifying property
  • Property with recovery period of 20 years or less
  • Placed in service after January 19, 2025
Example Savings Scenario

A $1M equipment purchase at 100% bonus depreciation generates a $1M Year 1 deduction, saving $370,000 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Virtual Assistant Home Office & Equipment Deduction

Virtual assistants working from home can deduct the home office space used exclusively for client work — typically $1,500–$4,000 per year. Also deduct computer equipment, monitors, keyboards, headsets, and any hardware used for client work under Section 179. A VA spending $3,000 on a new MacBook and monitor setup deducts the full amount in the year purchased.

Eligibility Requirements
  • Must be a self-employed virtual assistant
  • Must use a dedicated space in your home exclusively and regularly for VA work
  • Equipment must be used for VA work that generates income
  • Must report income on Schedule C
Example Savings Scenario

A virtual assistant using 10% of their home for work deducts $2,000/year in home office expenses, plus $1,500 in laptop and equipment, saving $1,295 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Graphic Designer Equipment & Home Office Deduction

Graphic designers can deduct computer equipment (iMac, MacBook Pro), external monitors, drawing tablets (Wacom Intuos Pro $500, Cintiq $1,500+), and any hardware used for design work under Section 179. A designer spending $5,000 on a new iMac and Wacom tablet deducts the full amount in year one. Also deduct the home office space used exclusively for design work.

Eligibility Requirements
  • Must be a self-employed graphic designer
  • Must use a dedicated space in your home exclusively and regularly for design work
  • Equipment must be used for design work that generates income
  • Must report income on Schedule C
Example Savings Scenario

A graphic designer using 12% of their home for design work deducts $2,400/year in home office expenses, plus $3,500 in equipment (iMac, Wacom tablet, monitor), saving $2,183 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §274 Uncle Kam Clients Only

Business Meals Deduction

Deduct 50% of the cost of business meals where there is a genuine business discussion. The meal must not be lavish, and the business purpose must be documented.

Eligibility Requirements
  • Meal has a bona fide business purpose
  • Business is discussed before, during, or after the meal
  • Document: who, what business discussed, date, amount
Example Savings Scenario

Spending $20,000/year on business meals = $10,000 deduction, saving $3,700 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §162 Uncle Kam Clients Only

Business Travel Deduction

Deduct ordinary and necessary travel expenses when traveling away from home for business, including transportation, lodging, and 50% of meals.

Eligibility Requirements
  • Travel away from your tax home for business
  • Travel requires sleep or rest (overnight trip)
  • Primary purpose of the trip is business
Example Savings Scenario

A business owner spending $15,000/year on travel (flights, hotels, meals) deducts $13,500 (meals at 50%), saving $4,995 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §51 Uncle Kam Clients Only

Work Opportunity Tax Credit (WOTC)

Employers receive a tax credit of $2,400 to $9,600 for each qualifying new hire from targeted groups including veterans, SNAP recipients, ex-felons, and long-term unemployed individuals.

Eligibility Requirements
  • Hire from a WOTC-targeted group
  • Employee works at least 120 hours in the first year
  • File Form 8850 within 28 days of the hire date
Example Savings Scenario

Hiring 10 qualifying employees at an average credit of $4,000 = $40,000 in direct tax credits, dollar-for-dollar against taxes owed.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §172 Uncle Kam Clients Only

Net Operating Loss (NOL) Carryforward

When business deductions exceed income, the resulting net operating loss can be carried forward indefinitely to offset future taxable income, reducing taxes in profitable years.

Eligibility Requirements
  • Business or individual with deductions exceeding income
  • NOL from trade or business activities
  • Carried forward indefinitely (limited to 80% of taxable income per year)
Example Savings Scenario

A startup with $200,000 in NOL carries it forward. In Year 3 with $300,000 profit, the NOL offsets $200,000, saving $74,000 in taxes.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Retirement IRC §408(k) Uncle Kam Clients Only

SEP-IRA Contribution

Self-employed individuals and small business owners can contribute up to 25% of net self-employment income (maximum $72,000 in 2026) to a SEP-IRA with minimal administrative requirements.

Eligibility Requirements
  • Self-employed or small business owner
  • Net self-employment income
  • Can be established and funded up to tax filing deadline including extensions
Example Savings Scenario

A freelancer earning $150,000 contributes $27,500 (25% × $110,000 net SE income) to a SEP-IRA, saving $10,175 in taxes at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Copywriter Home Office & Research Deduction

Copywriters working from home can deduct their dedicated home office space, all research materials (books, industry reports, subscriptions), and any databases or research tools used for client work. A copywriter spending $2,000 on industry research, competitor analysis tools, and reference materials deducts the full amount. Also deduct Grammarly, Hemingway, and writing software subscriptions.

Eligibility Requirements
  • Must be a self-employed copywriter or content writer
  • Must use a dedicated space in your home exclusively and regularly for writing
  • Research costs must be for copywriting work that generates income
  • Must report income on Schedule C
Example Savings Scenario

A freelance copywriter using 12% of their home for writing deducts $2,400/year in home office expenses, plus $1,200 in research and reference materials, saving $1,332 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Business Consultant Home Office & Professional Setup Deduction

Business consultants working from home can deduct the home office space used exclusively for client work and business activities. A 300 sq ft office in a 2,500 sq ft home yields a 12% deduction of all home expenses — typically $4,000–$10,000 per year. Also deduct all office equipment, furniture, and technology used for consulting work under Section 179.

Eligibility Requirements
  • Must be a self-employed business or management consultant
  • Must use a dedicated space in your home exclusively and regularly for consulting
  • Equipment must be used for consulting work that generates income
  • Must report income on Schedule C
Example Savings Scenario

A business consultant using 15% of their home for consulting deducts $4,500/year in home office expenses, plus $3,000 in equipment, saving $2,775 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Freelancer Home Office Deduction

Freelancers working from home can deduct the home office space used exclusively and regularly for business. The simplified method allows $5 per square foot (max 300 sq ft = $1,500 deduction). The actual expense method — deducting a percentage of rent, utilities, insurance, and internet — typically yields $3,000–$8,000 per year for most freelancers.

Eligibility Requirements
  • Must be a self-employed freelancer or independent contractor
  • Must use a dedicated space in your home exclusively and regularly for freelance work
  • Space must be your principal place of business
  • Must report income on Schedule C
Example Savings Scenario

A freelancer using 12% of their home for work deducts $2,400/year in home office expenses, saving $888 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Attorney Home Office & Law Library Deduction

Attorneys working from home can deduct their home office space and all law library expenses: Westlaw ($3,000–$10,000/yr), LexisNexis ($2,000–$8,000/yr), Casetext ($1,200/yr), and physical law books. A solo attorney spending $5,000/year on legal research databases deducts the full amount. Also deduct practice management software (Clio, MyCase, PracticePanther).

Eligibility Requirements
  • Must be a self-employed attorney or solo practitioner
  • Must use a dedicated space in your home exclusively and regularly for law practice
  • Law library and research materials must be for legal work
  • Must report income on Schedule C
Example Savings Scenario

A solo attorney using 15% of their home for law practice deducts $4,500/year in home office expenses, plus $2,400 in Westlaw and legal research tools, saving $2,553 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §280A Uncle Kam Clients Only

Photographer Studio & Home Office Deduction

Photographers can deduct a dedicated home studio space used exclusively for photography work — shooting, editing, and client meetings. A 400 sq ft studio in a 2,000 sq ft home yields a 20% deduction of all home expenses — typically $4,000–$10,000 per year. Also deduct editing software (Adobe Lightroom, Photoshop, Capture One), cloud storage, and gallery delivery platforms (Pixieset, ShootProof).

Eligibility Requirements
  • Must be a self-employed photographer
  • Studio must be used exclusively and regularly for photography business
  • Home studio qualifies if used exclusively for photography sessions or editing
  • Must report income on Schedule C
Example Savings Scenario

A photographer using 20% of their home as a studio deducts $5,000/year in home studio expenses, saving $1,850 at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Home Health Care Business IRC §199A Uncle Kam Clients Only

QBI Deduction (20% Pass-Through Deduction) for Home Care Agencies

Home health care businesses structured as sole proprietorships, partnerships, LLCs, or S-Corps may qualify for the Qualified Business Income (QBI) deduction under IRC §199A — a 20% deduction on net business income. For a home care agency generating $200,000 in net profit, this deduction alone saves $14,800 in federal taxes. Home health care is generally NOT classified as a Specified Service Trade or Business (SSTB), which means the income limitation phase-out that applies to doctors and lawyers typically does not apply — making this deduction available at higher income levels.

Eligibility Requirements
  • Home health care agency structured as LLC, S-Corp, or sole proprietor
  • Taxable income below $197,300 (single) or $394,600 (married) — full deduction
  • Income above thresholds: W-2 wage limitation applies
  • Home health care is generally NOT an SSTB — no income cap for most agencies
Example Savings Scenario

A home health care agency owner with $250,000 in net business income takes a $50,000 QBI deduction, saving $18,500 in federal taxes at 37%.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §164, State Law Uncle Kam Clients Only

Pass-Through Entity Tax (PTET) SALT Workaround

Many states allow S-Corps and partnerships to elect to pay state income tax at the entity level, generating a federal deduction that bypasses the $10,000 SALT cap for individual owners.

Eligibility Requirements
  • S-Corp or partnership in a state with a PTET election
  • Owners subject to state income tax on pass-through income
  • Election made at the entity level by the state deadline
Example Savings Scenario

An S-Corp owner in California paying $50,000 in state income tax: PTET election moves $40,000 above the SALT cap to a federal deduction, saving $14,800 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Home Health Care Business IRC §1361, §3111 Uncle Kam Clients Only

S-Corp Election for Home Health Care Business Owners

Home health care business owners operating as a sole proprietor or single-member LLC pay self-employment tax (15.3%) on 100% of net profit. By electing S-Corp status, the owner pays themselves a reasonable salary (subject to payroll taxes) and takes the remaining profit as distributions — which are NOT subject to self-employment tax. For a home care agency generating $200,000 in net profit, an S-Corp election typically saves $12,000–$20,000 per year in SE taxes alone.

Eligibility Requirements
  • Home health care business generating $40,000+ in net profit
  • Owner actively works in the business
  • Willing to run payroll and pay a reasonable salary
  • Entity structured as LLC or corporation
Example Savings Scenario

A home health care owner with $180,000 net profit pays a $75,000 reasonable salary and takes $105,000 as distributions, saving approximately $16,065 in self-employment taxes annually.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §62(a)(2)(A), Reg. 1.62-2 Uncle Kam Clients Only

Accountable Plan Reimbursements

Establish a formal accountable plan to reimburse employees (including owner-employees) for business expenses tax-free. The business deducts the reimbursement; the employee pays no income or payroll tax on it.

Eligibility Requirements
  • Operate as an S-Corp, C-Corp, or partnership
  • Expenses have a business connection
  • Employee substantiates expenses and returns excess amounts
Example Savings Scenario

An S-Corp owner with $15,000 in home office, vehicle, and phone expenses reimburses through an accountable plan, saving $5,550 in combined income and payroll taxes.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Therapist IRC §1361, §3111 Uncle Kam Clients Only

S-Corp Election for Therapists in Private Practice

Therapists operating as sole proprietors or single-member LLCs pay self-employment tax (15.3%) on 100% of net profit. By electing S-Corp status, the therapist pays themselves a reasonable salary (subject to payroll taxes) and takes remaining profit as distributions — which are NOT subject to self-employment tax. For a therapist generating $120,000 in net profit, an S-Corp election typically saves $8,000–$15,000 per year in SE taxes alone.

Eligibility Requirements
  • Net self-employment income of $50,000+ per year
  • Therapist actively works in the practice
  • Willing to run payroll and pay a reasonable salary
  • Entity structured as LLC or corporation
Example Savings Scenario

A therapist with $120,000 net profit pays a $60,000 reasonable salary and takes $60,000 as distributions, saving approximately $9,180 in self-employment taxes annually.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §1366 Uncle Kam Clients Only

S-Corp Owner Reasonable Salary & Distribution Strategy

S-Corp owners must pay themselves a reasonable salary for services rendered to the corporation — but can take additional profits as distributions not subject to self-employment tax. An S-Corp owner earning $200,000 in profit who pays themselves a $80,000 salary saves $18,360 in SE taxes on the $120,000 distribution. The IRS requires the salary to be comparable to what you would pay a third party for the same work.

Eligibility Requirements
  • Must be an S-Corp shareholder-employee
  • Must pay yourself a reasonable salary for services performed
  • Distributions above salary are not subject to SE tax
  • Must have consistent profitability to justify S-Corp election
Example Savings Scenario

An S-Corp owner with $150,000 in profit takes $75,000 as salary and $75,000 as distributions, saving $11,475 in SE tax vs. sole proprietor (15.3% on $75,000 = $11,475).

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §62(a)(2)(A) Uncle Kam Clients Only

S-Corp Owner Accountable Plan Reimbursement Strategy

S-Corp owners can reimburse themselves tax-free for business expenses through an Accountable Plan — home office, vehicle, phone, internet, and equipment. The corporation deducts the reimbursement as a business expense, and the owner receives it tax-free. An S-Corp owner reimbursing $12,000/year in home office and vehicle expenses saves $4,440 in taxes at 37%.

Eligibility Requirements
  • Must be an S-Corp shareholder-employee
  • Must have a written accountable plan policy
  • Expenses must have a business connection
  • Must substantiate expenses with receipts and documentation
Example Savings Scenario

An S-Corp owner reimbursing $12,000/year in home office, vehicle, and phone expenses through an accountable plan saves $4,440 in taxes at 37% - the reimbursements are tax-free to the employee and deductible to the S-Corp.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §7701 Uncle Kam Clients Only

LLC Owner Tax Election Strategy (Sole Prop vs. S-Corp vs. C-Corp)

LLC owners can elect to be taxed as a sole proprietorship (default), S-Corp, or C-Corp. The S-Corp election typically saves $5,000–$20,000 in self-employment taxes once net income exceeds $50,000. The C-Corp election (21% flat rate) benefits owners reinvesting profits in the business. The right election depends on income level, distribution needs, and business goals.

Eligibility Requirements
  • Must own an LLC (single-member or multi-member)
  • Single-member LLCs are taxed as sole proprietors by default
  • Multi-member LLCs are taxed as partnerships by default
  • Can elect S-Corp or C-Corp taxation by filing Form 2553 or Form 8832
Example Savings Scenario

An LLC owner with $120,000 in profit who elects S-Corp taxation saves $9,180 in SE tax by taking $60,000 as salary and $60,000 as distributions.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §41 Uncle Kam Clients Only

Research & Development (R&D) Tax Credit

A dollar-for-dollar tax credit for qualified research expenses including wages, supplies, and contract research. Startups can apply up to $500,000/year against payroll taxes.

Eligibility Requirements
  • Conducting qualified research activities (new or improved products/processes)
  • Incurring qualified research expenses (wages, supplies, contract research)
  • Startups with < $5M revenue can apply against payroll taxes
Example Savings Scenario

A software company spending $500,000 on R&D wages qualifies for a $50,000–$100,000 federal tax credit, dollar-for-dollar against taxes owed.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §831(b) Uncle Kam Clients Only

Captive Insurance Company

A business owner creates their own insurance company to insure business risks. Premiums paid to the captive are deductible by the business; the captive pays tax only on investment income under §831(b).

Eligibility Requirements
  • Business with $2M+ in annual revenue
  • Genuine insurable business risks
  • Captive receives $2.45M or less in premiums (§831(b) election)
  • Proper actuarial analysis and domicile compliance
Example Savings Scenario

A business paying $1.2M in captive premiums deducts the full amount, saving $444,000 at a 37% rate. The captive pays minimal tax on investment income.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §179D Uncle Kam Clients Only

179D Energy-Efficient Commercial Building Deduction

Deduct up to $5.00 per square foot for energy-efficient improvements to commercial buildings, including HVAC, lighting, and building envelope upgrades.

Eligibility Requirements
  • Own or design commercial buildings
  • Building meets energy efficiency standards (ASHRAE)
  • Architects, engineers, and designers can claim on government buildings
Example Savings Scenario

A 50,000 sq ft commercial building with qualifying improvements generates $250,000 in deductions, saving $92,500 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §162, §3121(b)(3) Uncle Kam Clients Only

Hiring Family Members in Your Business

Hire your children or spouse in your business to shift income to lower tax brackets. Children under 18 working for a sole proprietorship or partnership owned by parents are exempt from FICA taxes.

Eligibility Requirements
  • Sole proprietorship or partnership owned by parents
  • Children performing legitimate work for the business
  • Wages must be reasonable for the work performed
Example Savings Scenario

Paying a 16-year-old child $15,750/year (2026 standard deduction): $0 federal income tax for the child, $15,750 deduction for the business, saving $5,828 at a 37% rate.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §45F Uncle Kam Clients Only

Employer-Provided Childcare Credit

Employers who provide or pay for childcare facilities for employees receive a tax credit of 25% of qualifying childcare expenditures and 10% of childcare resource and referral expenditures, up to $150,000/year.

Eligibility Requirements
  • Employer provides or pays for childcare facilities
  • Qualifying childcare expenditures for employees
  • Credit limited to $150,000 per year
Example Savings Scenario

An employer spending $500,000 on an on-site childcare facility receives a $125,000 tax credit (25%), plus the remaining $375,000 is deductible.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
Business IRC §162 Uncle Kam Clients Only

YouTuber AdSense Income Structure & S-Corp Strategy

YouTubers earning AdSense income are self-employed and can deduct all channel-related expenses: equipment, editing software (Adobe Premiere, Final Cut Pro), music licensing (Epidemic Sound), stock footage, thumbnails (Canva), and channel management tools. Structuring as an S-Corp above $50,000 in net income saves $5,000–$15,000 in self-employment taxes annually.

Eligibility Requirements
  • Must have monetized YouTube channel (AdSense, memberships, Super Chat)
  • Must report YouTube income as self-employment income on Schedule C
  • Must have an LLC or business entity for larger channels
  • Income includes AdSense, channel memberships, Super Chat, and merchandise
Example Savings Scenario

A YouTuber with $100,000 in AdSense income structured through an S-Corp saves $7,650 in SE tax by taking $50,000 as salary and $50,000 as distributions.

Unlock the Full Strategy Breakdown — Free

Enter your email for instant access to MERNA strategy notes, IRS red flag warnings, action steps, and implementation guide.

No spam · No obligation · Instant access
What Most Business Owners Don't Know

The Augusta Rule is the most underused strategy for business owners who own their home.

An accountable plan can move $15,000–$30,000 of personal expenses into tax-free business reimbursements.

S-Corp salary optimization alone saves most owners $15,000–$40,000/year in payroll taxes.

Who Uses This Strategy

This write-off is commonly used by the following taxpayer profiles. Click to see all strategies for your situation.

Common Questions for Business Owners

Get answers to the most frequently asked tax questions for your profession.

What tax write-offs can a business owner claim?
Business owners can deduct payroll, rent, equipment (Section 179), vehicle expenses, business meals (50%), marketing, professional services, retirement plan contributions, health insurance, and home office. Most business owners miss $20,000\u2013$80,000 in deductions.
What is the Section 199A QBI deduction for business owners?
The QBI deduction allows pass-through business owners (LLCs, S-Corps, sole proprietors) to deduct up to 20% of qualified business income. On $200,000 of business income, this saves $8,800\u2013$14,800 in federal taxes.
Should a business owner elect S-Corp status?
Yes, for most business owners earning $60,000+ in net profit. An S-Corp election saves $5,000\u2013$30,000/year in self-employment taxes by allowing you to split income between salary and distributions.
Can a business owner deduct vehicle expenses?
Yes. Either the standard mileage rate (70 cents/mile in 2026) or actual expenses (gas, insurance, depreciation). For a vehicle used 80% for business with $15,000 annual costs, the deduction is $12,000.
How can a business owner maximize retirement contributions to reduce taxes?
A Solo 401(k) allows up to $70,000/year. A SEP-IRA allows 20% of net income (max $70,000). A defined benefit plan can allow $100,000\u2013$300,000+/year for older, high-income business owners.
0
0 write-offs saved
Tap to view your list

Your Biggest Missed Deduction Is Probably Locked Above

Uncle Kam clients save an average of $25,000–$120,000/year. The strategies that make that possible are unlocked on a free strategy call.

Book A Free Strategy Call Free consultation. No obligation.
';// ── Open in a new window and print ─────────────────────────────── var win = window.open('', '_blank', 'width=850,height=700,scrollbars=yes,noopener=0'); if (!win) { // Fallback: inject an iframe for printing if popup is blocked var iframe = document.createElement('iframe'); iframe.style.cssText = 'position:fixed;top:-9999px;left:-9999px;width:850px;height:700px;border:0;'; document.body.appendChild(iframe); iframe.contentDocument.open(); iframe.contentDocument.write(html); iframe.contentDocument.close(); setTimeout(function() { iframe.contentWindow.focus(); iframe.contentWindow.print(); setTimeout(function() { document.body.removeChild(iframe); }, 2000); }, 600); return; } win.document.open(); win.document.write(html); win.document.close(); win.focus(); setTimeout(function() { win.print(); }, 600); }// ── Email Unlock: post to GHL silently, expand locked cards ────────────── function ukwfUnlockStrategies(e) { e.preventDefault(); // Support both the main wall form AND per-card gate forms var form = e ? e.target : null; var gateInput = form ? form.querySelector('.ukwf-gate-email-input') : null; var mainInput = document.getElementById('ukwf-unlock-email'); var emailInput = (gateInput && gateInput.value.trim()) ? gateInput : mainInput; var errorEl = document.getElementById('ukwf-unlock-error'); var email = emailInput ? emailInput.value.trim() : ''; // Also check the gate input if main is empty if (!email && gateInput) email = gateInput.value.trim(); // Basic email validation if (!email || !/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(email)) { if (errorEl) errorEl.style.display = 'block'; if (gateInput) { gateInput.style.borderColor = '#ff6b6b'; gateInput.focus(); } else if (emailInput) emailInput.focus(); return; } if (errorEl) errorEl.style.display = 'none'; if (gateInput) gateInput.style.borderColor = ''; // Disable all unlock buttons document.querySelectorAll('.ukwf-email-unlock-btn, .ukwf-gate-email-btn').forEach(function(b) { b.disabled = true; b.textContent = 'Unlocking...'; }); // Send lead to GHL via server-side PHP AJAX (bypasses webhook workflow) var professionEl = document.querySelector('.ukwf-profile-name'); var professionName = professionEl ? professionEl.textContent.trim().replace(/\s*Tax Write-Offs\s*&?\s*Deductions\s*$/i, '').trim() : ''; var nameParts = professionName.split('/'); var ghlFirstName = nameParts[0] ? nameParts[0].trim() : professionName; var ghlLastName = nameParts[1] ? nameParts[1].trim() : 'Tax Write-Off Finder'; var ajaxUrl = (typeof ukwfConfig !== 'undefined' && ukwfConfig.ajaxUrl) ? ukwfConfig.ajaxUrl : '/wp-admin/admin-ajax.php'; var nonce = (typeof ukwfConfig !== 'undefined' && ukwfConfig.leadNonce) ? ukwfConfig.leadNonce : ''; var formData = new FormData(); formData.append('action', 'ukwf_ghl_lead'); formData.append('nonce', nonce); formData.append('email', email); formData.append('firstName', ghlFirstName); formData.append('lastName', ghlLastName); formData.append('profession', professionName); formData.append('source', 'ukwf-unlock'); formData.append('page', window.location.pathname); fetch(ajaxUrl, { method: 'POST', body: formData }).catch(function() {}); // fire-and-forget // Expand all locked cards immediately ukwfDoUnlock(); } function ukwfDoUnlock() { // Hide the email wall var wall = document.getElementById('ukwf-email-unlock-wall'); if (wall) { wall.style.transition = 'opacity 0.3s ease'; wall.style.opacity = '0'; setTimeout(function() { wall.style.display = 'none'; }, 300); } // Unlock all locked cards instantly — no stagger (stagger caused 4+ second delay for 70+ cards) var lockedCards = document.querySelectorAll('.ukwf-result-card--locked'); lockedCards.forEach(function(card) { // Remove locked state — keep collapsed so user can open each card individually card.classList.remove('ukwf-result-card--locked'); card.classList.add('ukwf-result-card--open'); // Clear any inline styles that might block the toggle var body = card.querySelector('.ukwf-result-body'); if (body) { body.style.display = ''; body.style.maxHeight = ''; } // Remove lock badge var badge = card.querySelector('.ukwf-result-lock-badge'); if (badge) badge.style.display = 'none'; // Replace the locked gate with an unlocked badge var gate = card.querySelector('.ukwf-locked-strategy-gate'); if (gate) { gate.innerHTML = '
Unlocked — tap to expand
'; } }); // Show success banner var banner = document.getElementById('ukwf-unlock-banner'); if (banner) { banner.style.display = 'flex'; } // Persist unlock in localStorage so it survives refresh, tab close, and navigation // Uses the same ukwfSetUnlocked() that the book-call path uses, which sets // localStorage key 'ukwf_unlocked' = '1'. The main script block already checks // ukwfIsUnlocked() on page load and calls ukwfUnlockAll() automatically. if (typeof ukwfSetUnlocked === 'function') { ukwfSetUnlocked(); } else { try { localStorage.setItem('ukwf_unlocked', '1'); } catch(err) {} } // Also run the main unlock function to handle any card variants we might miss if (typeof ukwfUnlockAll === 'function') { ukwfUnlockAll(); } } // NOTE: Auto-unlock on page load is handled by the main script block which // checks ukwfIsUnlocked() and calls ukwfUnlockAll(). No DOMContentLoaded // listener needed here (it was broken anyway because LiteSpeed defers scripts // past DOMContentLoaded)./* ── Sticky Save Bar ───────────────────────────────────────────────── */ (function() { var SAVED_KEY = 'ukwf_saved_v2'; var bar = document.getElementById('ukwf-sticky-save-bar'); var countEl = document.getElementById('ukwf-sticky-save-count'); var badgeEl = document.getElementById('ukwf-sticky-cart-badge'); var savingsWrap = document.getElementById('ukwf-sticky-save-savings'); var savingsRange = document.getElementById('ukwf-sticky-savings-range'); if (!bar || !countEl) return;var _prevCount = 0;/* Parse a savings string like "$1,200–$4,500/year" -> {min, max} */ function parseSavings(str) { if (!str) return null; var nums = str.replace(/[^0-9]/g, ' ').trim().split(/\s+/).filter(Boolean); var vals = nums.map(function(n) { return parseInt(n, 10); }).filter(function(n) { return !isNaN(n) && n > 0; }); if (vals.length === 0) return null; if (vals.length === 1) return { min: vals[0], max: vals[0] }; return { min: Math.min.apply(null, vals), max: Math.max.apply(null, vals) }; }/* Format a number as $XK or $X.XM */ function fmtMoney(n) { if (n >= 1000000) return '$' + (n / 1000000).toFixed(1).replace(/\.0$/, '') + 'M'; if (n >= 1000) return '$' + Math.round(n / 1000) + 'K'; return '$' + n.toLocaleString(); }/* Animated count-up for a single element */ function animateCount(el, from, to, duration) { if (from === to) { el.textContent = to; return; } var start = null; function step(ts) { if (!start) start = ts; var progress = Math.min((ts - start) / duration, 1); var ease = 1 - Math.pow(1 - progress, 3); el.textContent = Math.round(from + (to - from) * ease); if (progress < 1) requestAnimationFrame(step); else el.textContent = to; } requestAnimationFrame(step); }function getSaved() { try { return JSON.parse(localStorage.getItem(SAVED_KEY) || '[]'); } catch(e) { return []; } }function updateBar() { var saved = getSaved(); var n = saved.length;/* Count-up animation when count changes */ if (n !== _prevCount) { animateCount(countEl, _prevCount, n, 600); if (badgeEl) animateCount(badgeEl, _prevCount, n, 600); /* Pop animation on bar when count increases */ if (n > _prevCount) { bar.classList.remove('ukwf-sticky-bar-pop'); void bar.offsetWidth; bar.classList.add('ukwf-sticky-bar-pop'); } _prevCount = n; }if (n > 0) { bar.classList.add('ukwf-sticky-save-bar--visible');/* Calculate total savings range */ var totalMin = 0, totalMax = 0, hasSavings = false; saved.forEach(function(item) { var p = parseSavings(item.savings || ''); if (p) { totalMin += p.min; totalMax += p.max; hasSavings = true; } });if (hasSavings && savingsWrap && savingsRange) { var rangeStr = totalMin === totalMax ? fmtMoney(totalMin) : fmtMoney(totalMin) + '–' + fmtMoney(totalMax); savingsRange.textContent = rangeStr; savingsWrap.style.display = ''; } else if (savingsWrap) { savingsWrap.style.display = 'none'; } } else { bar.classList.remove('ukwf-sticky-save-bar--visible'); if (savingsWrap) savingsWrap.style.display = 'none'; } }/* Update whenever a save/unsave happens */ window.addEventListener('ukwfSavedChanged', updateBar); /* Cross-tab sync */ window.addEventListener('storage', function(e) { if (e.key === SAVED_KEY) updateBar(); }); /* Expose globally */ window.ukwfStickyBarRefresh = updateBar; updateBar(); })();/* ── CART DRAWER ────────────────────────────────────────────────────── */ (function() { var SAVED_KEY = 'ukwf_saved_v2'; var drawer = document.getElementById('ukwf-cart-drawer'); var overlay = document.getElementById('ukwf-cart-overlay'); var itemsList = document.getElementById('ukwf-cart-items'); var emptyEl = document.getElementById('ukwf-cart-empty'); var footerEl = document.getElementById('ukwf-cart-footer'); var savingsStrip = document.getElementById('ukwf-cart-savings-strip'); var savingsAmount = document.getElementById('ukwf-cart-savings-amount'); var headerSub = document.getElementById('ukwf-cart-header-sub'); var footerCount = document.getElementById('ukwf-cart-footer-count'); if (!drawer) return;function getSaved() { try { return JSON.parse(localStorage.getItem(SAVED_KEY) || '[]'); } catch(e) { return []; } } function setSaved(arr) { localStorage.setItem(SAVED_KEY, JSON.stringify(arr)); window.dispatchEvent(new CustomEvent('ukwfSavedChanged')); if (typeof window.ukwfStickyBarRefresh === 'function') window.ukwfStickyBarRefresh(); if (typeof window.ukwfSavedBadgeRefresh === 'function') window.ukwfSavedBadgeRefresh(); } function parseSavings(str) { if (!str) return null; var nums = str.replace(/[^0-9]/g, ' ').trim().split(/\s+/).filter(Boolean); var vals = nums.map(function(n){ return parseInt(n,10); }).filter(function(n){ return !isNaN(n) && n > 0; }); if (!vals.length) return null; if (vals.length === 1) return { min: vals[0], max: vals[0] }; return { min: Math.min.apply(null,vals), max: Math.max.apply(null,vals) }; } function fmtMoney(n) { if (n >= 1000000) return '$' + (n/1000000).toFixed(1).replace(/\.0$/,'') + 'M'; if (n >= 1000) return '$' + Math.round(n/1000) + 'K'; return '$' + n.toLocaleString(); } function getCatIcon(cat) { var icons = { 'vehicle':'', 'home':'', 'travel':'', 'equipment':'', 'health':'', 'retirement':'', 'education':'', 'real estate':'' }; var k = (cat || '').toLowerCase(); for (var key in icons) { if (k.indexOf(key) !== -1) return icons[key]; } return ''; } function renderItems() { var saved = getSaved(); var n = saved.length; /* Update header sub */ if (headerSub) headerSub.textContent = n + ' deduction' + (n !== 1 ? 's' : '') + ' saved'; /* Show/hide empty state */ if (emptyEl) emptyEl.style.display = n === 0 ? '' : 'none'; if (footerEl) footerEl.style.display = n === 0 ? 'none' : ''; /* Savings strip */ var totalMin = 0, totalMax = 0, hasSavings = false; saved.forEach(function(item) { var p = parseSavings(item.savings || ''); if (p) { totalMin += p.min; totalMax += p.max; hasSavings = true; } }); if (hasSavings && savingsStrip) { savingsStrip.style.display = ''; var rangeStr = totalMin === totalMax ? fmtMoney(totalMin) : fmtMoney(totalMin) + ' – ' + fmtMoney(totalMax); if (savingsAmount) savingsAmount.textContent = rangeStr; } else if (savingsStrip) { savingsStrip.style.display = 'none'; } /* Footer count */ if (footerCount) footerCount.textContent = n > 0 ? n + ' write-off' + (n !== 1 ? 's' : '') + ' in your list' : ''; /* Remove existing items (keep empty state) */ var existing = itemsList ? itemsList.querySelectorAll('.ukwf-cart-item') : []; existing.forEach(function(el) { el.parentNode.removeChild(el); }); /* Render each item */ saved.forEach(function(item, idx) { var div = document.createElement('div'); div.className = 'ukwf-cart-item'; div.style.animationDelay = (idx * 0.04) + 's'; div.innerHTML = '
' + getCatIcon(item.category) + '
' + '
' + '
' + escHtml(item.name || item.slug) + '
' + (item.category ? '
' + escHtml(item.category) + '
' : '') + (item.savings ? '
' + escHtml(item.savings) + '/yr
' : '') + '
' + ''; /* Remove button handler */ div.querySelector('.ukwf-cart-item-remove').addEventListener('click', function() { var slug = this.getAttribute('data-slug'); var arr = getSaved().filter(function(i){ return i.slug !== slug; }); setSaved(arr); /* Animate out */ div.style.transition = 'opacity 0.18s, transform 0.18s'; div.style.opacity = '0'; div.style.transform = 'translateX(20px)'; setTimeout(function() { renderItems(); }, 180); /* Also update save buttons on page */ document.querySelectorAll('.ukwf-card-save-btn[data-slug="' + slug + '"]').forEach(function(btn) { btn.classList.remove('ukwf-card-save-btn--saved'); btn.setAttribute('aria-pressed','false'); var lbl = btn.querySelector('.ukwf-card-save-label'); if (lbl) lbl.textContent = 'Save'; }); }); if (itemsList) itemsList.appendChild(div); }); } function escHtml(s) { return String(s).replace(/&/g,'&').replace(//g,'>').replace(/"/g,'"'); } function escAttr(s) { return String(s).replace(/"/g,'"').replace(/'/g,'''); } /* Open / close */ window.ukwfCartDrawerOpen = function() { renderItems(); if (drawer) drawer.classList.add('ukwf-cart-drawer--open'); if (overlay) overlay.classList.add('ukwf-cart-overlay--open'); document.body.style.overflow = 'hidden'; }; window.ukwfCartDrawerClose = function() { if (drawer) drawer.classList.remove('ukwf-cart-drawer--open'); if (overlay) overlay.classList.remove('ukwf-cart-overlay--open'); document.body.style.overflow = ''; }; window.ukwfCartClearAll = function() { if (!confirm('Remove all saved write-offs?')) return; setSaved([]); renderItems(); }; /* Keyboard close */ document.addEventListener('keydown', function(e) { if (e.key === 'Escape' && drawer && drawer.classList.contains('ukwf-cart-drawer--open')) { window.ukwfCartDrawerClose(); } }); /* Re-render when saves change */ window.addEventListener('ukwfSavedChanged', function() { if (drawer && drawer.classList.contains('ukwf-cart-drawer--open')) { renderItems(); } }); window.addEventListener('storage', function(e) { if (e.key === SAVED_KEY && drawer && drawer.classList.contains('ukwf-cart-drawer--open')) { renderItems(); } }); })();/* ── CARD SAVE BUTTONS ──────────────────────────────────────────────── */ (function() { var SAVED_KEY = 'ukwf_saved_v2';function getSaved() { try { return JSON.parse(localStorage.getItem(SAVED_KEY) || '[]'); } catch(e) { return []; } } function setSaved(arr) { localStorage.setItem(SAVED_KEY, JSON.stringify(arr)); } function isSaved(slug) { return getSaved().some(function(i) { return i.slug === slug; }); } function updateBtn(btn) { var slug = btn.getAttribute('data-slug'); var saved = isSaved(slug); btn.classList.toggle('ukwf-card-save-btn--saved', saved); btn.setAttribute('aria-pressed', saved ? 'true' : 'false'); var label = btn.querySelector('.ukwf-card-save-label'); if (label) label.textContent = saved ? 'Saved' : 'Save'; } function initAllBtns() { document.querySelectorAll('.ukwf-card-save-btn').forEach(function(btn) { updateBtn(btn); btn.addEventListener('click', function(e) { e.stopPropagation(); var slug = btn.getAttribute('data-slug'); var name = btn.getAttribute('data-name'); var cat = btn.getAttribute('data-category') || ''; var savings = btn.getAttribute('data-savings') || ''; var saved = getSaved(); var idx = saved.findIndex(function(i) { return i.slug === slug; }); if (idx === -1) { saved.push({ slug: slug, name: name, category: cat, savings: savings, savedAt: Date.now() }); } else { saved.splice(idx, 1); } setSaved(saved); updateBtn(btn); /* Sync badge and sticky bar */ window.dispatchEvent(new CustomEvent('ukwfSavedChanged')); if (typeof window.ukwfSavedBadgeRefresh === 'function') window.ukwfSavedBadgeRefresh(); if (typeof window.ukwfStickyBarRefresh === 'function') window.ukwfStickyBarRefresh(); }); }); } /* Init on load and re-sync on saved changes from autocomplete */ if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', initAllBtns); } else { initAllBtns(); } window.addEventListener('ukwfSavedChanged', function() { document.querySelectorAll('.ukwf-card-save-btn').forEach(updateBtn); }); })();