# Fresh — Full-Stack Web Framework for Deno > A next-generation web framework built for Deno with just-in-time rendering, island-based hydration, and zero build step. Pages are server-rendered by default with no client JS shipped unless opted in. ## Install Save in your project root: # Fresh — Full-Stack Web Framework for Deno ## Quick Use ```bash deno run -A -r https://fresh.deno.dev my-app cd my-app deno task start ``` ## Introduction Fresh is a full-stack web framework designed for Deno. It sends zero JavaScript to the client by default, using server-side rendering for all pages. Interactive components are loaded selectively through an islands architecture, resulting in fast page loads without a build step. ## What Fresh Does - Renders pages on the server with no client-side JS by default - Supports islands architecture for selective client-side hydration - Uses file-system routing (``routes/`` directory maps to URL paths) - Provides built-in middleware, error pages, and API route handlers - Runs on Deno Deploy for edge deployment or any Deno-compatible host ## Architecture Overview Fresh uses Preact as its rendering engine and compiles island components on demand using esbuild. Routes are defined as files in the ``routes/`` directory, where each file exports a handler and/or a component. Static assets are served from a ``static/`` directory. There is no build step during development; TypeScript and JSX are handled natively by Deno. ## Self-Hosting & Configuration - Requires Deno runtime (v1.35+ or Deno 2) - Configure via ``fresh.config.ts`` for plugins and middleware - Deploy to Deno Deploy with ``deployctl deploy`` - Self-host on any server with ``deno run -A main.ts`` - Add Tailwind CSS via the official plugin in the project scaffold ## Key Features - Zero-config TypeScript and JSX support through Deno - No build step required for development or production - Islands architecture sends JS only for interactive components - File-system routing with support for dynamic and catch-all routes - First-class integration with Deno Deploy for edge hosting ## Comparison with Similar Tools - **Next.js** — React-based with Node.js; Fresh uses Preact on Deno with no build step - **Astro** — content-focused with multi-framework islands; Fresh is Preact-only on Deno - **Remix** — relies on React and Node; Fresh is lighter with Deno-native tooling - **SvelteKit** — uses Svelte compiler; Fresh skips the build step entirely - **Hono** — minimal HTTP framework; Fresh is full-stack with routing and rendering ## FAQ **Q: Do I need Node.js to use Fresh?** A: No. Fresh runs entirely on Deno and does not use npm or Node.js. **Q: Can I use npm packages with Fresh?** A: Yes. Deno supports npm specifiers (``npm:package-name``), so most npm packages work. **Q: What is an island in Fresh?** A: An island is a Preact component placed in the ``islands/`` directory that gets hydrated on the client. Everything else remains server-rendered HTML. **Q: Is Fresh production-ready?** A: Fresh is used in production by Deno and other companies. It follows semantic versioning with stable releases. ## Sources - https://github.com/denoland/fresh - https://fresh.deno.dev/ --- Source: https://tokrepo.com/en/workflows/asset-c04c98ff Author: AI Open Source