# libtmux.Session.get_by_id

- **Module:** libtmux.Session
- **Package:** libtmux
- **Language:** Python
- **Kind:** method
- **Source:** https://github.com/tmux-python/libtmux/blob/9fdd083a8181a827889337b63cd4e6daea661a8c/src/libtmux/session.py#L1130
- **Page:** https://libtmux.org/en/py/latest/reference/libtmux-session-get_by_id/

```
libtmux.Session.get_by_id(self, session_id: str) -> Window | None
```

Return window by id. Deprecated in favor of :meth:`.windows.get()`.
