# server.Server.window_by_id

- **Module:** server.Server
- **Package:** libtmux
- **Language:** Rust
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-rs/blob/f0e37052c232636b61d095817046e6bfc8f2ca40/crates/libtmux/src/server/discovery.rs#L113
- **Page:** https://libtmux.org/en/rs/latest/reference/server-server-window_by_id/

```
server.Server.window_by_id(self, id: &WindowId) -> Result<Option<Window>, Error>
```

Find the window with this id, through the first link that reaches it.

A window linked into several sessions is returned once. Use
[`Server::windows`] when the link matters.

# Errors

Returns an error when the window listing fails.
