# Pph21 Grossup

> Solve circular PPh 21 tax allowance equations (Gross-Up) and evaluate PMK 66/2023 benefit-in-kind (Natura/Kenikmatan) monthly taxability thresholds.

- Skill: `adamriofc/pph21-grossup` (Agent Skill)
- Install (CLI): `npx skillmds@latest add adamriofc/pph21-grossup`
- Raw SKILL.md: https://api.skillmd.com/api/skills/adamriofc/pph21-grossup/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: adamriofc (https://skillmd.com/u/adamriofc)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/adamriofc/pph21-grossup

---


# PPh 21 Circular Gross-Up & Natura Tax Optimization

Calculates circular payroll tax allowances (*Gross-Up*) down to Rp 1 precision using iterative mathematical bisection, integrating PMK 66/2023 Benefit-in-Kind (*Natura/Kenikmatan*) taxability rules and PP 58/2023 TER tables.

## Circular Gross-Up & PMK 66/2023 Framework
1. **Mathematical Bisection Loop**:
   - Solves $\text{Tax Allowance} = \text{PPh 21}(\text{Base Salary} + \text{Allowances} + \text{Taxable Natura} + \text{Tax Allowance})$ iteratively.
   - Ensures employee Take-Home-Pay remains 100% untouched while employer deducts the tax allowance under UU PPh Pasal 6.
2. **Natura / Benefit-in-Kind Thresholds (PMK 66/2023)**:
   - Food & beverage provided to all employees: **100% tax-exempt**.
   - Standard housing & vehicle facilities: Exempt up to monthly statutory thresholds (e.g. Rp 2,000,000 exemption cap).
   - Excess Natura above exemption threshold is added to the monthly PPh 21 taxable gross base.

## Hybrid Execution Model
Pass parameters to `engines/pph21-grossup-calculator.js`:
* `calculatePPh21GrossUp({ baseSalary, regularAllowances, ptkpStatus, taxpayerIdentity, dateStr, naturaAmount, naturaExemptThreshold })`

## Worked Example
Input: Base salary Rp 15.000.000, PTKP TK/0, Natura amount Rp 3.000.000 (exemption Rp 2.000.000).
- Taxable Natura = `Rp 3.000.000 - Rp 2.000.000` = **Rp 1.000.000**.
- Base Taxable Cash = `Rp 15.000.000 + Rp 1.000.000` = **Rp 16.000.000**.
- Iterative Gross-Up Engine Output: Converges at `grossUpTaxAllowance` = **Rp 1.204.301**.
- Employee Net Take-Home-Pay = **Rp 15.000.000** (100% protected).

