+6
日增长
16,410
stars
973
forks
34
watchers
8,558
prs
1,767
issues
146
releases
README
Scalar
Interactive API Reference from OpenAPI/Swagger
└ Renders OpenAPI/Swagger documents
└ Comes with an API testing tool
└ Doesn't look like 2011
└ Generates code examples for many languages & frameworks
└ Integrates with your favorite framework
└ Try Demo
An offline-first API Client built for OpenAPI
└ Free and open-source
└ First-class OpenAPI/Swagger support
└ Integrates with dozens of API Frameworks (Elysia, Hono, FastAPI, etc)
└ Syncs with your favorite server framework (Watch Mode)
└ Has environment variables, dynamic parameters and everything
└ Try It in the Browser
└ Download (Windows, MacOS, Linux)
Trusted by:
Quickstart
Set up with your coding agent
Install the scalar-api-reference skill to give your coding agent guidance for framework integration, configuration, and troubleshooting:
bash
npx skills add scalar/scalar --skill scalar-api-reference
Copy this prompt into your coding agent from your project:
text
Set up Scalar API Reference in this project.
Inspect the project’s framework, package manager, routing, and existing
OpenAPI setup. Choose the appropriate framework integration from
https://scalar.com/products/api-references and install it using this
project’s conventions.
If no framework integration exists, render a route using the HTML/JS guide:
https://scalar.com/products/api-references/integrations/html-js
Also ask whether I want to request a framework integration here:
https://github.com/scalar/scalar/discussions/new?category=ideas
Serve the API reference at /scalar, or use an existing documentation route,
and connect it to the project’s OpenAPI document or generated endpoint.
If no OpenAPI document exists, ask me which source to use or whether
we need to add OpenAPI generation.
Use these guides for configuration and theming:
https://scalar.com/products/api-references/configuration
https://scalar.com/products/api-references/themes
Implement the setup, verify that the page loads and displays the API
documentation, and tell me how to run it locally and where to find it.
Set up with HTML
All you need is a single HTML file. Load the ESM build from our CDN, with no build step required:
html
Scalar API Reference
import { createApiReference } from 'https://cdn.jsdelivr.net/npm/@scalar/api-reference/esm.js'
createApiReference('app', {
// The URL of the OpenAPI document
url: 'https://registry.scalar.com/@scalar/apis/galaxy?format=json',
// Avoid CORS issues
proxyUrl: 'https://proxy.scalar.com',
})
Need a Custom Header? Check out this example: https://codepen.io/scalarorg/pen/VwOXqam
And there's an ever-growing list of plugins and integrations:
Integrations
- HTML/JS API (works everywhere)
- .NET ASP.NET Core
- Aspire
- AdonisJS
- Astro
- Django Ninja
- Django
- Docker
- Docusaurus
Top issues
#2410CSS Leaks when using Vue components inside another app17 comments · 2024-07-05#4458Vue/Nuxt Hydration Error9 comments · 2025-01-14#4977API Client does not set field name correctly in [FromForm] requests contains list7 comments · 2025-03-05#10795Safari blocks desktop authentication callback to localhost on macOS4 comments · 2026-10-30#5553select multiple files4 comments · 2025-05-02#10982Goes to new line in headers section on keyboard KeyUp event3 comments · 2026-11-12#11054postman-to-openapi: saved response bodies are written as bare examples, so the output is not valid OpenAPI 3.10 comments · 2026-11-14#11049Code examples drop file uploads and send `null` binary bodies for OpenAPI 3.0 and Swagger 2.0 documents0 comments · 2026-11-14
Discussions
#11021Option to disable or redirect persistence of the selected client1 comments · 2026-11-13#11018feat(api-reference): Display x-badges in sidebar navigation1 comments · 2026-11-12#10926Source commit and version-bound MIT notice for scalar-fastapi 1.9.11 comments · 2026-11-09#10872Option to keep deepObject query parameters collapsed on the reference page1 comments · 2026-11-05#10772Is there a supported way to set the frontend `localization` option from the Spring Boot integration?2 comments · 2026-10-29#10766Consider alternative color pickers in CodeMirror0 comments · 2026-10-28#10747Sharing via developer tools1 comments · 2026-10-23#10692a router: 'none' option ?1 comments · 2026-10-19
Latest release
Release 2026-11-12 release-2026-11-12-7e9d6bd 2026-11-12Releases @scalar/[email protected] Minor Changes - 10967: fix: parse YAML documents that merge shared anchors into many operations Since yaml 2.9.1, merge keys (<<: anchor) count toward the alias limit, so large API Gateway exports failed with "Excessive alias count indicates a resource exhaustion attack". The limit is now 100,000 and shared through YAML_MAX_ALIAS_COUNT from @scalar/helpers. Patch Changes - 10979: Preserve question marks inside query values when merging a URL and path. @scalar/[email protected] Patch Changes - 10977: Use the API title for JSON and YAML do