# Configure the logging system

Tiledesk uses [Winston](https://github.com/winstonjs/winston) as logging library. The Tiledesk server is configured with the following transports :

* the console
* logs files under /logs/app.log folder

## Configure the log level

The default log level is INFO. If you want to change the log level use the `LOG_LEVEL` environment property as follow:

```
LOG_LEVEL="verbose"
```

## Enable logs to MongoDB

Optionally you can write the logs to the MongoDB database (adding a MongoDB transport to Winston) with the following environment property:

```
WRITE_LOG_TO_MONGODB="true"
```

You can also change (default value is INFO) the level for the MongoDB transport with the following property:

```
LOG_MONGODB_LEVEL="error"
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.tiledesk.com/configuration/logging.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
