Deno logoDeno

Using JSX

Deno Deploy supports JSX (and TSX) out of the box. You don't need an additional transform step to use JSX with Deno Deploy.

The example below demonstrates the usage of JSX on Deno Deploy.

/** @jsx h */
/// <reference no-default-lib="true"/>
/// <reference lib="dom" />
/// <reference lib="dom.asynciterable" />
/// <reference lib="deno.ns" />

import { serve } from "";
import { h, renderSSR } from "";

function App() {
  return (
        <title>Hello from JSX</title>
        <h1>Hello world</h1>

function handler(req) {
  const html = renderSSR(<App />);
  return new Response(html, {
    headers: {
      "content-type": "text/html",


You can run the above example with deno run.

deno run --allow-net=:8000

It is important that you use a .jsx or .tsx file extension, so Deno Deploy knows to interpret a given file as JSX/TSX.