# tmux.Window.SelectPane

- **Module:** tmux.Window
- **Package:** github.com/libtmux/libtmux-go/tmux
- **Language:** Go
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-go/blob/5f808882015a975a65acc7f9da5b3ff0d5cbdc91/tmux/window_pane_topology.go#L133
- **Page:** https://libtmux.org/reference/go/tmux-window-selectpane/

```
tmux.Window.SelectPane(ctx: context.Context, request: WindowSelectPaneRequest) -> (Pane, error)
```

SelectPane makes an exact or relative pane active in the receiver's exact winlink without selecting the window in its session. Target must belong to that same SessionID and WindowID; a PaneID alone does not identify a linked view. The returned [Pane] is the freshly materialized active pane in the receiver context, not a canonical ID-only view.

Command or refresh failures return zero because active-pane selection has no
reliable partial identity. Transport errors are delivery-ambiguous.
