# Open a catalog in the editor

Copy as Markdown[View as Markdown](/docs/editor/how-to/open-catalog.md)

***

EventCatalog Editor needs a local catalog directory before it can show resources.

## How the editor finds a catalog[​](#how-the-editor-finds-a-catalog "Direct link to How the editor finds a catalog")

When you run `npx @eventcatalog/editor`, the editor looks for a catalog in this order:

1. The path passed with `--catalog`
2. The current directory, if it contains `eventcatalog.config.js`
3. The first child directory containing `eventcatalog.config.js`
4. The catalog path screen in the browser

## Open a catalog from the CLI[​](#open-a-catalog-from-the-cli "Direct link to Open a catalog from the CLI")

Pass the catalog path:

```
npx @eventcatalog/editor --catalog /path/to/my-catalog
```

Use an absolute path when possible. It makes it clear which catalog the editor is changing.

## Open a catalog from the browser[​](#open-a-catalog-from-the-browser "Direct link to Open a catalog from the browser")

If the editor cannot find a catalog automatically, it shows a catalog path screen.

Enter the path to your EventCatalog project and choose **Open**.

## Fix catalog loading errors[​](#fix-catalog-loading-errors "Direct link to Fix catalog loading errors")

If the editor cannot open the catalog, check that:

* The path points to the catalog root
* The directory contains `eventcatalog.config.js`
* The config file can be imported by Node.js
* Dependencies for the catalog are installed

If you are not sure what the catalog root should look like, read the [EventCatalog project structure guide](/docs/development/getting-started/project-structure.md).
