OpenAPI / Swagger Viewer
Paste or open an OpenAPI 3.x or Swagger 2.0 spec (YAML or JSON) and browse every endpoint, parameter and response.
Open a spec file
.yaml, .yml or .json — max 5 MB
Loading YAML parser…
What the viewer does
An OpenAPI (formerly Swagger) document describes an HTTP API: its paths, the methods allowed on each path, the parameters and request bodies they accept, and the responses they return. The files are precise but hard to read once they grow past a few hundred lines — you scroll through nested YAML, jump to components to resolve a $ref, and lose track of which path you were in.
This viewer parses the document properly (YAML with the open-source yaml library, JSON with the browser's parser) and turns it into a list of operations grouped by tag. Each operation expands to show its parameters, request body and responses with references already resolved. It is handy for reviewing a pull request that changes a spec, checking what a third-party API expects before writing a client, or getting an overview of an internal API without spinning up Swagger UI.
How to use it
- Paste your document into OpenAPI / Swagger document, or drop a file on Open a spec file. Load sample shows a small Bookstore API.
- The summary card shows the title, version, spec version, servers and the number of operations and schemas. Syntax errors appear in red with the line and column.
- Type in the search box to filter operations by path, method, summary, operationId or tag.
- Click an operation to expand its details. Open Schemas at the bottom to see each model and its property types.
Worked example
The sample declares a path-level parameter by reference and two operations under it:
/books/{bookId}:
parameters:
- $ref: "#/components/parameters/BookId"
get:
tags: [Books]
summary: Get a book by ID
responses:
"200":
content:
application/json:
schema: { $ref: "#/components/schemas/Book" }The viewer lists GET /books/{bookId} and DELETE /books/{bookId} under the Books tag. Both inherit the path-level parameter, shown as bookId · path · string (uuid) · required, and the 200 response of the GET reads application/json → Book. The DELETE is struck through with a Deprecated badge because the sample sets deprecated: true. Note that the parameters key itself is not listed as a method — only the eight HTTP methods (get, put, post, delete, options, head, patch, trace) are.
Reading the result
- Parameters — name, location (
path,query,header,cookieor Swagger'sformData), type and whether it is required. Path parameters are always required. When a path-level and operation-level parameter share a name and location, the operation's version wins, as the specification requires. - Request body — each media type with its schema. For Swagger 2.0, the
in: bodyparameter is shown here using theconsumeslist. - Responses — status codes (green for 2xx, red for 4xx/5xx), the description and the media types with their schema names.
- Types — referenced schemas appear by name (
Book), arrays asarray<Book>, formats in brackets and compositions asoneOf(A | B).
Limitations
- External references (
./schemas/user.yamlor URLs) are not fetched; bundle multi-file specs first. - Nested schemas are summarised by type, not expanded field by field inside each operation.
- Security schemes, callbacks, webhooks and links are not displayed.
- There is no "try it out"; requests are never sent. Files are limited to 5 MB.
Tips and common mistakes
- Quote status codes in YAML (
"200":). Some tools treat unquoted numbers as integers and reject the document. - Duplicate keys are an error. Writing the same path twice — once for
getand again fordelete— is invalid YAML; put both methods under one path key. - Watch indentation. A method indented one level too deep becomes a child of another method and silently disappears from the list.
- Need to switch formats? Use the YAML to JSON converter or JSON to YAML. To try GraphQL APIs instead, see the GraphQL query builder.
Frequently Asked Questions
Which OpenAPI versions does the viewer support?
OpenAPI 3.0 and 3.1 and Swagger 2.0, in YAML or JSON. Swagger 2.0 body parameters are shown as a request body, and host, basePath and schemes are combined into the server URL.
Does it validate my OpenAPI spec?
It reports YAML and JSON syntax errors with line and column (including duplicate keys) and warns when the openapi/swagger field or paths object is missing. It does not validate the document against the full OpenAPI schema; use a linter such as Spectral for that.
Are $ref references resolved?
Local references inside the same document (for example #/components/schemas/User or #/definitions/Pet) are followed for parameters, request bodies and responses, and schema references are shown by name. References to other files or URLs are not fetched.
Can I load a spec from a URL?
No. Paste the document or open a .yaml, .yml or .json file from your computer (up to 5 MB). Fetching URLs from the browser would be blocked by CORS for most APIs anyway.
Can I try out requests like in Swagger UI?
No. This is a read-only explorer for reviewing endpoints, parameters and responses quickly; it does not send requests to your API.
Is my API specification uploaded anywhere?
No. The file is read and parsed in your browser with the open-source yaml library, and nothing is sent to a server — useful for internal or unreleased APIs.
Related tools
- UUID GeneratorGenerate RFC 4122 compliant UUIDs (v1, v4, v5) in bulk. Export as JSON, CSV, or plain text.
- Lorem Ipsum GeneratorGenerate Lorem Ipsum placeholder text in paragraphs, sentences, or words with optional HTML output.
- QR Code GeneratorGenerate customizable QR codes for URLs, text, emails, WiFi, vCards, and phone numbers.
- QR Code ScannerScan QR codes with your camera or from an image file directly in the browser. Copy the result, open safe links and see the decoded content type.
- Regex TesterTest, debug, and visualize regular expressions against sample text in real time with match highlighting.
- SQL Formatter & BeautifierFormat and beautify SQL queries with proper indentation, keyword capitalization, and syntax highlighting.
Found a bug or a wrong result? Report it.