1. EasyHost
  2. Errors
  3. ERR_MODULE_NOT_FOUND on startup

ERR_MODULE_NOT_FOUND on startup

ES modules need full file extensions, and TypeScript does not always add them.

Last updated November 9, 2026

The error

Error [ERR_MODULE_NOT_FOUND]: Cannot find module imported from dist/index.js

Why it happens

ES modules need full file extensions, and TypeScript does not always add them.

How to fix it

Use .js extensions in relative imports, or bundle with a tool such as tsup.

import { db } from "./db.js";

Still stuck

Read the build log and runtime logs, or browse all errors.

Start for free

Install the skill, choose Global or Local, then tell your agent to deploy. No credit card, no config files.

npx ezhst skill install