logtape is a free, open source monitoring & observability project written in TypeScript and released under MIT. It has 1,998 GitHub stars, 55 forks and 12 open issues, and was last pushed 3 days ago. On this registry it ranks #152 of 191 tracked projects in Monitoring & Observability, with 5 head-to-head comparisons available.

LogTape

JSR npm Bundlephobia GitHub Actions Codecov

LogTape is a logging library for JavaScript and TypeScript designed with a library-first philosophy. Unlike traditional loggers, LogTape is unobtrusive—libraries can safely log without any configuration, while applications retain full control. With zero dependencies and universal runtime support, it works seamlessly across Deno, Node.js, Bun, browsers, and edge functions.

The highlights of LogTape are:

  • Zero dependencies: LogTape has zero dependencies. You can use LogTape without worrying about the dependencies of LogTape.

  • Library support: LogTape is designed to be used in libraries as well as applications. You can use LogTape in libraries to provide logging capabilities to users of the libraries.

  • Runtime diversity: LogTape supports Deno, Node.js, Bun, edge functions, and browsers. You can use LogTape in various environments without changing the code.

  • Structured logging: You can log messages with structured data.

  • Hierarchical categories: LogTape uses a hierarchical category system to manage loggers. You can control the verbosity of log messages by setting the log level of loggers at different levels of the category hierarchy.

  • Template literals: LogTape supports template literals for log messages. You can use template literals to log messages with placeholders and values.

  • Built-in data redaction: LogTape provides robust capabilities to redact sensitive information from logs using pattern-based or field-based approaches.

  • Dead simple sinks: You can easily add your own sinks to LogTape.

  • Framework integrations: First-class support for popular frameworks like Express, Fastify, GraphQL Yoga, Hono, Koa, and Drizzle ORM with automatic HTTP request logging, GraphQL server logging, and database query logging.

LogTape web console output LogTape terminal output

Installation

LogTape is available on JSR and npm. You can install LogTape for various JavaScript runtimes and package managers:

deno add jsr:@logtape/logtape  # for Deno
npm  add     @logtape/logtape  # for npm
pnpm add     @logtape/logtape  # for pnpm
yarn add     @logtape/logtape  # for Yarn
bun  add     @logtape/logtape  # for Bun

See also the installation manual for more details.

Packages

LogTape is a monorepo that contains several packages. The main package is @logtape/logtape, which provides the core logging functionality. Other packages provide additional features and integrations. The following is a list of the packages in the LogTape monorepo:

Package JSR npm Description
@logtape/logtape [JSR][jsr:@logtape/logtape] [npm][npm:@logtape/logtape] Core logging functionality
@logtape/adaptor-bunyan [JSR][jsr:@logtape/adaptor-bunyan] [npm][npm:@logtape/adaptor-bunyan] [Bunyan] adapter
@logtape/adaptor-log4js [JSR][jsr:@logtape/adaptor-log4js] [npm][npm:@logtape/adaptor-log4js] [log4js] adapter
@logtape/adaptor-pino [JSR][jsr:@logtape/adaptor-pino] [npm][npm:@logtape/adaptor-pino] [Pino] adapter
@logtape/adaptor-winston [JSR][jsr:@logtape/adaptor-winston] [npm][npm:@logtape/adaptor-winston] [winston] adapter
@logtape/cloudwatch-logs [JSR][jsr:@logtape/cloudwatch-logs] [npm][npm:@logtape/cloudwatch-logs] [AWS CloudWatch Logs] sink
@logtape/config [JSR][jsr:@logtape/config] [npm][npm:@logtape/config] Object-based configuration
@logtape/drizzle-orm [JSR][jsr:@logtape/drizzle-orm] [npm][npm:@logtape/drizzle-orm] Drizzle ORM integration
@logtape/elysia [JSR][jsr:@logtape/elysia] [npm][npm:@logtape/elysia] [Elysia] integration
@logtape/express [JSR][jsr:@logtape/express] [npm][npm:@logtape/express] Express integration
@logtape/fastify [JSR][jsr:@logtape/fastify] [npm][npm:@logtape/fastify] Fastify integration
@logtape/graphql-yoga [JSR][jsr:@logtape/graphql-yoga] [npm][npm:@logtape/graphql-yoga] GraphQL Yoga integration
@logtape/hono [JSR][jsr:@logtape/hono] [npm][npm:@logtape/hono] Hono integration
@logtape/koa [JSR][jsr:@logtape/koa] [npm][npm:@logtape/koa] Koa integration
@logtape/lint [JSR][jsr:@logtape/lint] [npm][npm:@logtape/lint] ESLint/Oxlint/Deno Lint rules
@logtape/file [JSR][jsr:@logtape/file] [npm][npm:@logtape/file] File sinks
@logtape/otel [JSR][jsr:@logtape/otel] [npm][npm:@logtape/otel] [OpenTelemetry] sink
@logtape/pretty [JSR][jsr:@logtape/pretty] [npm][npm:@logtape/pretty] Beautiful text formatter
@logtape/redaction [JSR][jsr:@logtape/redaction] [npm][npm:@logtape/redaction] Data redaction
@logtape/sentry [JSR][jsr:@logtape/sentry] [npm][npm:@logtape/sentry] [Sentry] sink
@logtape/syslog [JSR][jsr:@logtape/syslog] [npm][npm:@logtape/syslog] Syslog sink
@logtape/testing [JSR][jsr:@logtape/testing] [npm][npm:@logtape/testing] Testing utilities
@logtape/testing-bun [JSR][jsr:@logtape/testing-bun] [npm][npm:@logtape/testing-bun] Bun test integration
@logtape/testing-deno [JSR][jsr:@logtape/testing-deno] Deno test integration
[*@logtape/tes

readme truncated — read the full docs on github

Frequently asked questions

Is logtape free to use?

logtape is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does logtape do?

Unobtrusive logging library with zero dependencies for Deno, Node.js, Bun, browsers, and edge functions

What is logtape written in?

logtape is primarily written in TypeScript. Its source is publicly available at https://github.com/dahlia/logtape, and it has 1,998 GitHub stars.