# KV_REDIS_URL_UNUSED

<!-- Generated by docs/modules/diagnostics from the package catalogs. Write a guide in docs/diagnostics/<CODE>.md instead of editing this file. -->

KV does not select the Redis driver just because `REDIS_URL` is set or `KV_URL` contains a `rediss://` URL.

To use `REDIS_URL`, set the driver explicitly:

```ts [vite.config.ts]
import { defineConfig } from 'vite'
import { vitehub } from 'vite-hub'

export default defineConfig({
  plugins: [vitehub({ kv: { driver: 'redis' } })],
})
```

To use `KV_URL`, set the driver and point it at that variable:

```ts [vite.config.ts]
import { defineConfig } from 'vite'
import { vitehub } from 'vite-hub'

export default defineConfig({
  plugins: [vitehub({ kv: { driver: 'redis', url: 'env:KV_URL' } })],
})
```

If KV should keep using its current store instead, set that store's driver explicitly.

## Source

`KV_REDIS_URL_UNUSED` belongs to the `kv` package. Its catalog entry is in [`src/error-diagnostics.ts`](https://github.com/vite-hub/vitehub/blob/main/packages/kv/src/error-diagnostics.ts#L195). It is raised in [`src/config.ts`](https://github.com/vite-hub/vitehub/blob/main/packages/kv/src/config.ts#L238), [`src/config.ts`](https://github.com/vite-hub/vitehub/blob/main/packages/kv/src/config.ts#L240).

See [all KV diagnostics](https://vitehub.dev/docs/kv/diagnostics).

<!-- vitehub-docs:section-links -->
## In this section

- [Overview](https://vitehub.dev/raw/docs/kv.md)
- [Get started](https://vitehub.dev/raw/docs/kv/get-started.md)
- [Configure](https://vitehub.dev/raw/docs/kv/configure.md)
- [Server API](https://vitehub.dev/raw/docs/kv/server-api.md)
- [Agent capability](https://vitehub.dev/raw/docs/kv/agent-capability.md)
- [Hosts](https://vitehub.dev/raw/docs/kv/hosts.md)
- [Limits and errors](https://vitehub.dev/raw/docs/kv/limits-and-errors.md)

Next: [KV_INVALID_INPUT](https://vitehub.dev/raw/docs/kv/diagnostics/kv_invalid_input.md)

All pages: [llms.txt](https://vitehub.dev/llms.txt)
