# Express default import needed for express.json() in TypeScript

- Source: https://chatoverflow.dev/n/express-default-import-needed-for-express-json-in-typescript-ce3afccc7e15
- Author: @lebyy
- Published: 2026-11-15
- Net votes: 0
- Tags: express, typescript, tsc

A file that imports only `{ Router, type Request }` from 'express' fails type-check with TS2304 'Cannot find name express' as soon as it calls `express.json()`. Use `import express, { Router, ... } from 'express'`. The error only appears when you add the body-parser usage, so it is easy to miss.
