Case study
Live productTakarLaba: marketplace profit calculator
A web app with a free calculator that itemizes Shopee, TikTok Shop & Tokopedia, and Lazada fees, then works out net profit, the break-even price, and the ad spend limit.
- Role
- Product planning, fee research, development, testing, and launch
- Stack
- Node.js 24
- TypeScript
- Hono
- SQLite
- Zod
- esbuild
- PWA
- Status
- Online:Visit takarlaba.com: TakarLaba (opens another site)
This product’s source code is private. The evidence is in the test results below and on the live site.


The problem
Sellers on Shopee, TikTok Shop & Tokopedia, and Lazada pay a stack of deductions: admin fees, order processing fees, free shipping programs, dynamic commissions, and logistics service fees. Each platform structures them differently, and some fees are capped per product.
The rates also change often. During 2026, several platforms raised fees together in May, the dynamic commission cap changed in September, and Shopee’s Gratis Ongkir XTRA (free shipping) fee goes up on December 1. A price that used to be safe can quietly lose its margin.
The solution
TakarLaba stores the official rates per category and subcategory, each with a link to its source and the date it was last checked. Sellers enter a selling price, a product cost, and a category. Every deduction then appears line by line, next to net profit, margin, the break-even price, and the ad spend limit (break-even ROAS).
The fee engine is a single TypeScript module shared by the browser and the server. Numbers update as you type, and the form still works without JavaScript. The calculator is free without signing up, and a free account saves 3 products that are recalculated with the latest rates every time they are opened.
Key features
- Calculators for Shopee (including Mall), TikTok Shop & Tokopedia, and Lazada, with the formula behind every deduction
- Break-even price and the ad spend limit per order (break-even ROAS)
- A switch to apply the Shopee rates that take effect on December 1, 2026
- Rate tables for each platform, linked to the official pages
- Calculations can be shared by link or WhatsApp
- Free accounts with email or Google sign-in: 3 saved products, data export, and self-service account deletion
- Installable on a phone as an app (PWA), and the calculator keeps working offline
- A paid Pro plan, open since October 25, 2026: unlimited products, target-margin pricing, campaign simulation, and bulk calculations of up to 500 rows from CSV
Technical challenges
Rates that change by date
Every rate stores the date it takes effect, and the engine picks rates by the date in Jakarta time. Announced changes, such as Shopee’s program fees from December 1, 2026, can be simulated before they apply. Saved products are always recalculated with the current rates.
A break-even price that respects fee caps
Some fees are capped per product, so the break-even price cannot be found with a single formula. TakarLaba finds it with a binary search that runs the full fee engine at every step.
One engine, checked against official examples
The same engine powers the server, the browser, and the social media content pipeline. Its unit tests compare results with the platforms’ own worked examples, and content production stops if a number in a video script does not match the engine.
Secure, with as little data as possible
TakarLaba uses a strict CSP with no inline scripts, hashed session tokens, double-submit CSRF protection, and rate limits on sign-in and sign-up. Visitors without an account get no cookies, and the analytics keep daily totals only, with no IP addresses.
Test results
Lighthouse (mobile)
Home page and calculator
Measured page: /
Shopee rate table
Measured page: /tarif/shopee
Measured on October 25, 2026 with Lighthouse 13.5.0 in mobile mode, directly against the live site. Scores are the median of 3 runs.
Automated tests
- Unit tests: the fee engine (checked against the platforms’ official examples), server and security, accounts, and the number checks for content scripts Vitestreport of October 22, 2026174
- End-to-end tests: calculating and sharing links, the form without JavaScript, rate pages and the PWA, and an account from sign-up to deletion, on a Pixel 7 and desktop Chrome Playwrightreport of October 18, 202610
184 tests in total, all passing according to the project’s test reports on the dates shown.