---
title: ":host()"
description: "Documentation for the vlt client and the vlt registry."
url: "https://docs.vlt.io/client/selectors/pseudo-classes/host"
image: "https://docs.vlt.io/og/client/selectors/pseudo-classes/host"
lang: "en"
---

# :host()

The `:host()` pseudo-class switches the current graph context to a new set of graphs loaded from a specific host context. This allows querying across multiple projects or switching to different project scopes.

## Syntax

```
:host(<context>)
```

The context parameter can be:

- A specific project folder path (e.g., `"file:~/my-project"`)
- The special `local` context — loads all configured projects from your vlt dashboard

## Examples

### Find malware across all projects

```bash title="Terminal"
$ vlt query ':host(local) :malware'
```

### Query a specific project

```bash title="Terminal"
$ vlt query ':host("file:~/my-app") :outdated'
```

### Bump version for a remote project

```bash title="Terminal"
$ vlt version patch --scope=':host("file:~/tmp/test-vite")'
```

### Get all direct deps across local projects

```bash title="Terminal"
$ vlt pkg pick name version --scope=':host(local) > :root > *'
```

## How it works

When you use `:host()`, vlt:

1. Resolves the context to one or more project directories
2. Loads the dependency graph for each project
3. Runs the rest of the selector against all loaded graphs

This is particularly useful for organization-wide audits and cross-project dependency analysis.

## See also

- [`:diff()`](https://docs.vlt.io/client/selectors/pseudo-classes/diff.md) — find changed packages
- [`:outdated()`](https://docs.vlt.io/client/selectors/pseudo-classes/outdated.md) — find packages with newer versions
