UniMarket

How we built UniMarket: a fast, bilingual marketplace on one server

The choices behind UniMarket, from Bangla fonts and one-codebase architecture to orders from several shops, money stored in whole poisha, email deliverability and one-command deploys.

UniMarket is a multi-seller marketplace for Bangladesh in Bangla and English. We built the store, the Seller Center, the admin panel and the installable app as one TypeScript project and run it on our own server. This is a tour of the decisions that mattered most, and why we made them.

A UniMarket category page in dark theme with a row of products, each with a price, a discount badge and an Add button.
A category page on desktop.

The stack and why

LayerChoiceWhy
AppNext.js 16, React 19 and TypeScriptServer-rendered pages keep browser JavaScript small, and one language covers the store, Seller Center, admin and API.
StylingTailwind CSS 4 with design tokensSmall CSS, and light and dark themes from the same tokens.
DataMongoDB with its own instanceFlexible documents suit products with different options, and a separate instance leaves other services on the server untouched.
Sign-inOne-time codes, Google and Apple, Firebase Auth for phone codesShoppers in Bangladesh sign in with a phone number, and a code needs no password to forget.
HostingOur own VPS, nginx, Cloudflare and Let’s EncryptPredictable cost and full control over backups, mail and limits.

Fast pages, including in Bangla

Most pages a visitor sees are public, so they are built to be cached. Anything personal, like the cart count or a signed-in name, is filled in separately and does not hold the page back. Images are converted to modern formats at fixed sizes when they are uploaded.

Fonts were the surprise. A Bangla web font is big: the one we tried was about 200 KB. In our test it cost more than ten points of the mobile Lighthouse performance score. So Bangla text uses the font that is already on the phone or computer, and a small self-hosted font covers only Latin letters and numbers. Readers see the font they read every day, and nothing extra downloads.

In our local production build, Accessibility, Best Practices and SEO scored 100 on every page we tested, and mobile Performance was between 93 and 98. Those are our own measurements on a local build, and adding third-party scripts later would lower them.

Two languages that really are two languages

Bangla and English each have their own address, with hreflang links between them so search engines show the right one. Every interface string lives in a typed dictionary, and the build fails if a Bangla string is missing, so a half-translated page cannot ship. Prices use Bangla digits in Bangla and Latin digits in English.

One checkout, several sellers

A cart can hold items from several shops. When the shopper places the order, checkout works out every price again from the database instead of trusting the browser, reserves the stock in one atomic step, splits the order into one shipment per shop and charges one delivery fee per shop. Submitting twice does not create two orders, and cancelling puts the stock back.

Money is stored as whole poisha, where one taka is 100 poisha, so no sum is ever rounded by a decimal.

Safe by default

  • Sellers can only read their own orders and products, and staff get only the permissions of their role. Staff sign in with a password and an authenticator code, and their changes go into an audit log.
  • The web server limits sign-in and API requests, and the app adds its own per-user limits.
  • Uploads are re-encoded, which strips hidden location data from photos, and identity documents are stored outside the public folder.
  • After a security review we fixed the two account-takeover findings first and the medium findings after that.

Email that arrives

UniMarket sends an email at every order step, so deliverability is part of the product. Mail goes out through our own mail server with a DKIM signature, and the domain publishes SPF and DMARC records. In our tests the order emails passed all three checks and reached the inbox, not spam.

Deploying without breaking open tabs

A deploy builds on the server, switches to the new release and checks that it is healthy. A second command goes back to the previous release. Each release has its own deployment id, so when a shopper leaves a tab open across a deploy, the page notices that its buttons belong to an old release and reloads itself, instead of showing an error.

The database is backed up every night and the last 14 backups are kept.

UniMarket is in early access with a demo catalogue. The marketplace is live and working, and a unimarket.bd domain is planned.

Facts checked by the 22Softwares team against the live UniMarket app and its Seller Center guide.

Questions

What is UniMarket built with?

Next.js 16, React 19 and TypeScript on the front and back end, Tailwind CSS 4 for styling, MongoDB for data and Firebase for phone sign-in and push notifications.

Why does UniMarket use the device’s own Bangla font?

A Bangla web font was large enough to cost more than ten points of the mobile Lighthouse performance score in our test. The device’s own font costs nothing to download and is the font people already read.

Can 22Softwares build a marketplace like this for me?

Yes. We design, build and run multi-seller stores end to end: storefront, seller tools, admin, payments, delivery, email and hosting.