> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Config Dir • AI Agent SDK

> get_config_dir: Get PraisonAI config directory (editable config, credentials, rules).

# get\_config\_dir

<div className="flex items-center gap-2">
  <Badge color="teal">Function</Badge>
</div>

> This function is defined in the [**paths**](../modules/paths) module.

Get PraisonAI config directory (editable config, credentials, rules).

Precedence:

1. `PRAISONAI_HOME` / existing legacy home (single root, back-compat)
2. `$XDG_CONFIG_HOME/praisonai` (else `~/.config/praisonai`)

## Signature

```python theme={"theme":{"light":"vitesse-light","dark":"vitesse-dark"}}
def get_config_dir() -> Path
```

### Returns

<ResponseField name="Returns" type="Path">
  Path to config directory
</ResponseField>

## Used By

* [`get_config_path`](../functions/get_config_path)
* [`get_all_paths`](../functions/get_all_paths)

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/paths.py#L194">
  `praisonaiagents/paths.py` at line 194
</Card>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Configuration Overview" icon="gear" href="/docs/docs/configuration/index" />

  <Card title="Agent Config" icon="robot" href="/docs/docs/configuration/agent-config" />
</CardGroup>
