Skip to main content
Back to Projects
In ProgressFeaturedFull Stack

Afia — Arabic Medical Publishing Platform & Editorial Studio

An Arabic-first medical publishing platform: a fast, SEO-ready public site with medically reviewed articles, health calculators and AdSense support, and an editorial studio with an independent medical-review workflow, revision history and two-factor sign-in. NestJS, GraphQL, PostgreSQL, Next.js and React.

Afia medical publishing platform on desktop and phone

Overview

Project Overview

Afia (عافية) is an Arabic-first medical publishing platform built from a client brief: a public website of medically reviewed health articles, a drug directory, interactive health calculators, and an editorial studio where writers draft, independent medical reviewers approve, and administrators publish. It is designed to meet Google's expectations for health content (E-E-A-T, structured data, AdSense policies) from the first line.

Three apps share one GraphQL API: a NestJS backend on PostgreSQL, a Next.js public site (right to left, with optional English), and a React studio in Arabic and English with light and dark themes.

Public Website

  • Article template with breadcrumb, author and medical reviewer bylines, published, updated and last-reviewed dates, a quick clinical facts table (specialty, symptoms, diagnosis, ICD-10), key takeaways, comparison tables, numbered references, and a required "when to see a doctor / emergency" box
  • FAQ as native details elements, related articles, author and reviewer profile pages, and a medical disclaimer under every article
  • Four calculators that run in the browser: BMI, pregnancy due date, calories and water, and ovulation
  • Health library, medical categories, live search, About with the medical team, a contact form with honeypot, rate limit and Turnstile, and a real 404 page
  • SEO: schema.org structured data, sitemaps, RSS feeds, llms.txt, canonical and hreflang links; AdSense review and live modes behind Google Consent Mode, never on policy pages, search or 404

Editorial Studio and Review Workflow

  • Draft → pending medical review → approved → published; any edit of approved or published content sends it back to draft and takes it off the site
  • Approval applies to one exact revision, by a verified reviewer who is neither the author nor the last editor; saves use optimistic concurrency, transactions, full revision snapshots and an audit trail
  • Quality rules enforced by the API (drug monographs need 14 sections and 600+ words; no placeholder text reaches the site)
  • Rich-text editor, people and reviewer profiles, categories, reader messages inbox, site settings, and a launch-readiness report that lists exactly what is still missing
  • Staff two-factor authentication (authenticator app and recovery codes), with an option to require it for admins and reviewers at the API level

Engineering and Quality

Self-hosted IBM Plex Sans Arabic, image uploads re-encoded to WebP with metadata removed, CDN purge of the exact affected URLs on publish, edit and unpublish, backups with a restore drill, and Docker, Compose and nginx deployment files. A 17-stage QA script runs unit tests, PostgreSQL integration tests, browser flows for publishing and two-factor sign-in, GraphQL limits and access control, AdSense and launch modes, cache headers, and accessibility (axe) and lab Web Vitals checks.

Status: the engineering side of the brief is implemented and tested. Launch waits on the client's real medical content, reviewer identities, legal text and AdSense account. The screenshots show demo content.

Gallery

14 screenshots

Technologies

Next.js 16React 19TypeScriptNestJSGraphQLApollo ClientPostgreSQLTypeORMTailwind CSS 4Radix UIViteSchema.org / SEOGoogle AdSense & Consent ModeCloudflare TurnstileTOTP Two-Factor AuthDockernginxPlaywrightaxe / Web Vitalsi18n / RTL

Next step

Got a project in mind?

I'm available for freelance and contract work. Let's discuss what you're building.