# Development setup

This page describes how to run Weaviate from source (git checkout / tarball) locally.

:::callout{intent="tip"}
You can find the source code at the [Weaviate repo](https://github.com/weaviate/weaviate/tree/master).
:::

Prerequisites:

- [Go](https://go.dev/dl/) v1.21 or higher
- (optional) [Docker](https://docs.docker.com/desktop/)

## Running from source

The fastest way to run Weaviate from source is to issue the command below:

```bash
tools/dev/run_dev_server.sh <configuration>
```

Where `<configuration>` is _one_ of the server configuration (`$CONFIG`) values in [`/tools/dev/run_dev_server.sh`](https://github.com/weaviate/weaviate/blob/master/tools/dev/run_dev_server.sh#L26). For example, you can run:

```bash
tools/dev/run_dev_server.sh local-openai
```

To run the server locally with the OpenAI module.

The default configuration is `local-development` which will run the server locally with the `text2vec-contextionary` and `backup-filesystem` modules.

You can also create your own configuration. For instance, you can clone an entry (`local-all-openai-cohere-google` is a good start) and add the required [environment variables](../database-configuration/overview.md).

## Running with Docker

To run with Docker, start up the Weaviate container and the container(s) for any additional services with

```bash
tools/dev/restart_dev_environment.sh [additional_services]
```

then run the development server as described in the section above.

For example, the setup below uses Docker Compose to spin up Prometheus and Grafana instances. Those are pre-configured to scrape metrics from Weaviate. Using this setup, you can:

- access Weaviate on port `8080`
- access Grafana on port `3000` (Login: `weaviate`/`weaviate`)
- if necessary for debugging - access prometheus directly on port `9090`

```bash
tools/dev/restart_dev_environment.sh --prometheus && tools/dev/run_dev_server.sh local-no-modules
```

:::callout{intent="info"}
This setup is for contributors to the Weaviate code base. If you are an end-user of Weaviate looking for a Prometheus-enabled example, please see [this documentation page](../monitoring-and-logging/monitoring.md) or this [example](https://github.com/weaviate/weaviate-examples/tree/main/monitoring-prometheus-grafana).
:::

Below are more examples of running Weaviate with Docker.

### Transformers t2v only

```bash
tools/dev/restart_dev_environment.sh --transformers && ./tools/dev/run_dev_server.sh local-transformers
```

### Contextionary t2v & Transformers QnA

```bash
tools/dev/restart_dev_environment.sh --qna && ./tools/dev/run_dev_server.sh local-qna
```

The above commands are subject to change as we add more modules and require specific combinations for local testing. You can always inspect [restart\_dev\_environment.sh](https://github.com/weaviate/weaviate/blob/master/tools/dev/restart_dev_environment.sh) and [run\_dev\_server.sh](https://github.com/weaviate/weaviate/blob/master/tools/dev/run_dev_server.sh) to see which options are available. The first option without any arguments is always guaranteed to work.

To make queries from a web interface, use the [WCD console](/go/console?utm_content=others) to connect to `localhost:8080`.

## Further resources

- [Weaviate GitHub repository](https://github.com/weaviate/weaviate/)

## Questions and feedback

Have a question or feedback? Here's how to reach us.

::::card-grid
:::card{title="Community Forum" href="https://forum.weaviate.io/c/support" icon="messages-square"}
Ask questions and connect with other developers on our **Community forum**.
:::

:::card{title="Support" href="/guides/support-overview" icon="life-buoy"}
Weaviate Cloud user or customer? Find the right channel on the **Support page**.
:::
::::

## Related pages

- [Agents](./agents-index.md)
- [AI-assisted Weaviate code generation](./ai-assisted-vibe-coding-index.md)
- [APIs](./apis-index.md)
- [Authorization and authentication](./authorization-and-authentication-index.md)
- [Benchmarks](./benchmarks-index.md)
- [Best practices](./best-practices-index.md)
- [Client libraries](./clients-index.md)
- [Client Libraries / SDKs](./client-libraries-index.md)
- [Cloud](./cloud-index.md)
- [Cloud account management](./cloud-account-management-index.md)

# Agent Instructions

This portal answers questions programmatically. To receive a synthesized,
source-cited answer instead of crawling page by page, append the `?ask=`
query parameter to any page URL on this site:

    /guides/quickstart?ask=how+do+I+authenticate

Optional parameters:

- `&goal=<what-you-are-trying-to-do>` steers the answer toward your
  objective (e.g. `&goal=write+a+python+client`).
- `&version=<label>` scopes the answer to a mounted version when the
  portal publishes more than one.

The response is `text/markdown`: the answer followed by a `# Sources` list
of the portal pages it was grounded in. Status codes are the contract:

- `200` — the answer; `402` — the portal owner’s plan or answer credits are
  exhausted (surface this to your operator; do NOT retry); `429` — you are
  rate-limited; back off for the `Retry-After` seconds; `503` — the answer
  lane is temporarily unavailable; fall back to crawling the `.md` pages.

For the full corpus map read `llms.txt` at the site root; for the tool
surface (search + page fetch as MCP tools) see `/mcp`.
