# libtmux_mcp.tools.window_tools.move_window

- **Module:** libtmux_mcp.tools.window_tools
- **Package:** libtmux-mcp
- **Language:** Python
- **Kind:** function
- **Source:** https://github.com/tmux-python/libtmux-mcp/blob/4daddc0dfca96c43bf521d818bf91564e1434760/src/libtmux_mcp/tools/window_tools.py#L444
- **Page:** https://libtmux.org/en/py/stable/mcp/reference/libtmux_mcp-tools-window_tools-move_window/

```
libtmux_mcp.tools.window_tools.move_window(
    window_id: str | None = None,
    window_index: str | None = None,
    session_name: str | None = None,
    session_id: str | None = None,
    destination_index: str = "",
    destination_session: str | None = None,
    socket_name: str | None = None,
) -> WindowInfo
```

Move a window to a different index or session.

Reorder windows within a session or move a window to another session.

## Parameters

- `window_id` (`str | None`): Window ID (e.g. '@1').
- `window_index` (`str | None`): Window index within the session.
- `session_name` (`str | None`): Source session name.
- `session_id` (`str | None`): Source session ID.
- `destination_index` (`str`): Target window index. Default empty string (next available).
- `destination_session` (`str | None`): Target session name or ID. Default is current session.
- `socket_name` (`str | None`): tmux socket name.

## Returns

WindowInfo
    Serialized window after move.
