@matthewp/astro-fastify 2.0

A new version of my Astro Fastify adapter has been released. You can see the release notes here:

You'll want to install 2.0.1 as that contains a bug fix.

The big change in this release is support for TypeScript in your Fastify routes. The adapter allows you to specify an entrypoint that receives the Fastify object where you can do things like define routes and add plugins. Now that entrypoint can be TypeScript (or any other format compiled by Vite). For example:

import { defineConfig } from 'astro/config';
import fastify from '@matthewp/astro-fastify';

export default defineConfig({
  output: 'server',
  adapter: fastify({
    entry: new URL('./api/index.ts', import.meta.url),

Astro + Fastify + Starter

Additionally the starter has been updated to use the new version of @matthewp/astro-fastify, and to use TypeScript for the entrypoint, as well as some clean ups. You can get that here: is a great choice as a host when using Astro, both with Fastify or with any other Node.js framework because it makes deployments so easy and you get the benefit of their global network.