Documentation
v1.0.0
Frontend
React.js

Deploy React.js

React apps fit Mekong hosted deployment well when you upload the compiled frontend output instead of the raw source project.

Use the static template in the dashboard for both React Classic and React Vite.

React Vite

Build the app so Vite creates dist/:

npm run build

Zip the contents inside dist/, not the parent folder:

cd dist
zip -r ../react-vite.zip .

Upload react-vite.zip with the React Vite template in /dashboard/deploy.

React Classic

For Create React App or older React setups that compile into build/:

npm run build
cd build
zip -r ../react-classic.zip .

Upload react-classic.zip with the React Classic template in /dashboard/deploy.

What the archive should look like

After unzip, the archive root should look like this:

index.html
assets/...
static/...

The important part is that index.html is directly at the top level of the archive.

Dashboard flow

  1. Run the production build
  2. Zip only the generated output folder contents
  3. Open /dashboard/deploy
  4. Choose React Classic or React Vite
  5. Upload the archive and choose your subdomain
  6. Wait for the live URL

Best fit

Hosted deployment works well for:

  • single-page React apps
  • static marketing sites
  • React builds produced by Vite or Create React App
  • frontend-only dashboards and admin panels

When to use a tunnel instead

Use a normal Mekong tunnel if your React project depends on:

  • a live dev server with HMR
  • a backend running on your machine
  • server-side rendering

For development, see the existing Vite and Next.js tunnel guides.