Dosu LogoDosu Logo
Ask
Join our Discord
Kubb's SpacePublic
Kubb
DocumentsKubb's Space
faq
faq
Type
External
Status
Published
Created
Sep 2, 2026
Updated
Sep 2, 2026
Source
docs/5.x/community/faq.md

FAQ#

If your question isn't here, ask in Discord or open a GitHub issue.

General#

Who should use Kubb?#

Use Kubb when you need more than types from a spec. It generates clients, hooks, validators, and mocks in one run. It fits monorepos and any project where keeping generated code in sync by hand has become a chore.

Is Kubb production-ready?#

Yes. The generated code is plain TypeScript. It has no runtime dependency on Kubb, no decorators, and no framework lock-in.

Is Kubb free and open source?#

Yes. MIT license, developed in the open on GitHub.

Compatibility#

Does Kubb work with JavaScript projects?#

Yes. Kubb generates TypeScript. You can consume the output directly in a JavaScript project or transpile it as part of your build.

Can I use Kubb with GraphQL?#

Not out of the box. The default adapter targets OpenAPI/Swagger. For GraphQL, use GraphQL Code Generator. A custom adapter can handle any format, but writing one takes real work.

What Node.js version is required?#

Node.js 22 or higher. The CLI and config file are ESM-native.

Does Kubb support Bun or Deno?#

The CLI and generated code run on Bun with no extra configuration. Deno isn't officially tested.

Using Kubb#

How do I update generated code when my API changes?#

Re-run kubb generate. Use the clean option to remove stale files before each run.

npx kubb generate

Do I commit generated files to Git?#

Either way works. Many teams commit the generated code so CI can skip regeneration. Others add the output directory to .gitignore and generate during CI.

Can I customize the generated code?#

Yes. Each plugin exposes a resolver option to rename operations and types, and a macros option to rewrite AST nodes before they are written to disk. For deeper control, write a custom plugin.

Can I run multiple configs in one command?#

Yes. Pass an array to defineConfig and each entry generates from its own input, output, and
plugins. See multiple configurations
for the shape and how to combine it with the function form.

Does Kubb work inside a bundler (Vite, webpack, etc.)?#

Yes. unplugin-kubb integrates Kubb into Vite, Rollup, Rolldown, webpack, Rspack, esbuild, Farm, Nuxt, and Astro.

Can I run Kubb in CI?#

Yes. kubb generate is a standard Node.js command. Set DO_NOT_TRACK=1 to silence telemetry.

How do I disable telemetry?#

Set DO_NOT_TRACK=1 or KUBB_DISABLE_TELEMETRY=1. See Telemetry for details.

Plugins#

Do I need to install every plugin?#

No. Each plugin is an independent npm package. Install only what you need.

Can I write a custom plugin?#

Yes. Use definePlugin from kubb/kit. The Creating Your First Plugin guide walks through a full example.

Where can I find all available plugins?#

The Plugins registry lists every official and community plugin.

Documents
Axios Plugin
a-working-mcp-server-from-a-spec
base-url
basic-usage
build-a-url-without-sending
calling-operations
choose-the-client-when-two-are-registered
class-based-sdk
claude-mcp-plugin
comparison
ecosystem
generate
generators
index
index
installation
introduction
kubb-invalid-plugin-options
kubb-plugin-failed
migration
nuxt
options
options
parsers
plugin-client
plugin-cypress
plugin-mcp
plugins
point-at-an-env-driven-host
point-at-an-env-driven-host
query-errors-transport
README
recipes
register-handlers-with-a-server
rspack
serialization
serialization
stream-server-sent-events
transport
typed-request-helpers-against-staging
v5
validate-every-api-response
validate-requests-and-responses
validate-requests-and-responses
OpenAPI Schema Conversion
a-working-mcp-server-from-a-spec
adapter-oas
adapters
ast
calling-operations
calling-operations
changelog
class-based-sdk
claude
claude-code-plugin
claude-mcp-plugin
coerce-query-and-form-input
comparison
contributing
downgrade-int64-to-a-plain-number
ecosystem
encode-a-custom-type-on-requests
faq
format-date-fields-with-dayjs
generate
generators
How can you extend Kubb's generated code to access OpenAPI security schemes inside fetch functions, so each generated client knows which security scheme it requires?
index
index
index
index
index
index
index
index
introduction
kubb-adapter-required
kubb-deprecated
kubb-invalid-document
kubb-invalid-server-variable
kubb-plugin-failed
kubb-ref-not-found
kubb-unsupported-format
map-spec-types-to-native-ts
migration
nuxt
options
parsers
plugin-mcp
plugin-ts
plugin-zod
plugins
prefix-every-schema-type-name
printers
README
recipes
rspack
serialization
serialization
serialization
tree-shakeable-enums
v3
v5
Package Version Management
init
kubb-plugin-failed
kubb-update-available
migration
nuxt
parsers
rspack
React Query Code Generation
basic-usage
calling-operations
calling-operations
calling-operations
claude-code-plugin
comparison
custom-query-keys
custom-query-keys
generate
generators
generators
immutable-requests
index
index
index
infinite-scroll-query
infinite-scroll-query
installation
introduction
kubb-plugin-failed
kubb-plugin-not-found
migration
nuxt
options
options
options
parsers
plugin-client
plugin-mcp
plugin-react-query
plugin-swr
plugin-vue-query
plugins
reactive-params-that-refetch
README
recipes
resolvers
rspack
skip-a-request-until-ready
suspense-hooks
v3
v5
wrap-hooks-with-shared-options
AGENTS
CLAUDE
CONTRIBUTING
GEMINI
SKILL
SKILL
What new feature was proposed and implemented for the `kubb-cli` tool regarding OpenAPI/Swagger file validation?
a-barrel-in-every-folder
adapters
architecture
ast
astro
authentication
authentication
authentication
auto-generated-mock-data
barrel
barrel-files
base-url
base-url
build-a-url-without-sending
configuration
copilot-instructions
creating-plugins
deterministic-data-with-a-seed
diagnostics
diagnostics
engine
error-handling
error-handling
error-handling
esbuild
exclude
farm
grouping
handlers-you-fill-from-tests
hooks
include
index
index
index
index
index
index
interceptors
interceptors
interceptors
jsx
kit
kit
kubb-clean-root
kubb-format-failed
kubb-input-not-found
kubb-input-request-failed
kubb-input-required
kubb-input-unreachable
kubb-legacy-input
kubb-lint-failed
kubb-path-traversal
kubb-performance
kubb-plugin-info
kubb-plugin-warning
kubb-post-generate-failed
kubb-unknown
llmstxt
localized-mock-data
macros
macros
macros-option
markdown
mcp
mcp
named-re-exports-for-tree-shaking
one-wildcard-barrel
options
options
options
options
options
options
options
options
options
options
output-banner
output-footer
override
parsers
plain-language
plugin-faker
plugin-msw
plugins
prefix-every-generated-type-name
printers
pull_request_template
renderers
renderers
resolvers
resolvers
resolvers
rolldown
rollup
security
server-sent-events
server-sent-events
standalone-api-docs-page
storage
storage
strip-descriptions-with-a-macro
strip-descriptions-with-a-macro
telemetry
testing
transport
transport
tree-shakeable-schemas-with-zod-mini
turn-barrels-on
usa-english
v4
validate
vite
webpack
zod-as-the-single-source-of-truth