# libtmux.Pane.split_window

- **Module:** libtmux
- **Package:** libtmux
- **Language:** Python
- **Kind:** method
- **Source:** https://github.com/tmux-python/libtmux/blob/38e368c11117fb4aeb2f082d552cd4f210eae06a/src/libtmux/pane.py#L2743
- **Page:** https://libtmux.org/en/py/stable/reference/libtmux-pane-split_window/

```
libtmux.Pane.split_window(
    self,
    target: int | str | None = None,
    attach: bool = False,
    start_directory: StrPath | None = None,
    vertical: bool = True,
    shell: str | None = None,
    size: str | int | None = None,
    percent: int | None = None,
    # deprecated,
    environment: dict[str, str] | None = None,
) -> Pane
```

Split window at pane and return newly created :class:`Pane`.

## Deprecated

0.33 — Deprecated in favor of :meth:`.split`.

## Parameters

- `target` (`int | str | None`)
- `attach` (`bool`): Attach / select pane after creation.
- `start_directory` (`StrPath | None`): specifies the working directory in which the new pane is created.
- `vertical` (`bool`): split vertically
- `shell` (`str | None`)
- `size` (`str | int | None`)
- `percent` (`int | None`): percentage to occupy with respect to current pane
- `# deprecated`
- `environment` (`dict[str, str] | None`): Environmental variables for new pane. Passthrough to ``-e``.
