Kosmora
100% offline · Free to use

Kosmora maps your MongoDB universe.

A visual MongoDB schema designer for VS Code. Draw your collections, link them together and export them to the code you need, without leaving the editor or connecting to a database.

11export formats
14field types
0network calls
Kosmora schema designer in dark mode
Everything in one place

Design and export

Kosmora gives you a whiteboard for your data model and turns it into code, in one extension that never needs the internet or a database.

Visual schema designer

Drag collections onto a canvas, add nested objects and arrays, and link references. Arrows show how your data connects.

Export to real code

Generate JSON Schema, MongoDB validators, Mongoose, TypeScript, Prisma, Pydantic, Markdown, Mermaid, DBML, SVG and PNG.

Every field detail

Set types, required, unique, enums, defaults, ranges, patterns and descriptions, plus compound, text and TTL indexes, in one side panel.

Live problem checking

Spot duplicate names, invalid field names and references to missing collections while you design.

Git-friendly designs

Designs are plain .kosmora.json files. The Schema Designs view lists them all, and they diff and review well in Git.

Light and dark themes

A clean Material Design interface that follows your VS Code theme, with keyboard shortcuts, auto-arrange and zoom.

Get going in minutes

Three steps to your first schema

No account, no sign-up and no server needed to start designing.

Install

Install Kosmora from the VS Code Marketplace, or from the .vsix file if you're offline.

Design

Run Kosmora: New Sample Schema from the Command Palette, then add collections and fields on the canvas.

Export

Click Export and pick a format, or export every format at once into a folder you choose.

Take a look

Clean, modern and familiar

A Material Design interface with light and dark themes that follow VS Code.

Designer

The schema designer: collections, fields and references on one canvas.

Export formats

One design, every format

Keep your schema as a single .kosmora.json file in Git and generate the rest.

JSON SchemaDraft 2020-12
MongoDB validatorsmongosh script with indexes
MongooseCommonJS or ESM
TypeScriptInterfaces
PrismaMongoDB provider
PydanticPython v2 models
MarkdownDocs with diagram
MermaidER diagram
DBMLdbdiagram.io
SVGVector image
PNGRaster image
Private by design

Works completely offline

Kosmora runs entirely on your computer. Your schemas never leave it.

  • No telemetry, no tracking, no accounts.
  • No fonts, scripts or images loaded from the internet.
  • It never connects to a database or any server.
  • Your designs are ordinary files that stay in your project.
Editing a collection in the designer
Questions

Frequently asked

Is Kosmora free?

Yes. Kosmora is free to download and use for personal, educational and commercial work. It is proprietary software, so you may not republish, redistribute or modify it.

Do I need a MongoDB server?

No. Kosmora never connects to a database. You design on the canvas and export files, and you decide where to use them.

How do I use the MongoDB validator export?

It's a mongosh script that creates your collections with $jsonSchema validation and indexes. Review it, then run it yourself with mongosh against the database you choose.

Where are my schema designs stored?

In ordinary .kosmora.json files in your project, so you can commit and review them in Git like any other file.

Who is responsible for my data?

You are. Kosmora never touches a database; it only creates files. Review generated code and scripts, and test them on a non-production copy before using them on real data. Kosmora is provided "as is", and its owner accepts no liability for data loss or other damage. See section 6 of the license.

How do I report a problem?

Open an issue on GitHub. Please include your VS Code version, Kosmora version and steps to reproduce.

Ready to design?

Install Kosmora for free, or download the user manual to read offline.