---
title: Installation
sidebar_label: Installation
description: 'Learn how to install the Apify SDK for Python using pip and manage dependencies for your Actor projects.'
---

import Tabs from '@theme/Tabs';
import TabItem from '@theme/TabItem';
import CodeBlock from '@theme/CodeBlock';

## Requirements

The Apify SDK requires Python version 3.10 or above to run Python Actors locally.

## Installation

The Apify Python SDK is available as [`apify`](https://pypi.org/project/apify/) package on PyPi. To install it, run:

```bash
pip install apify
```

When you create an Actor using the Apify CLI, the Apify SDK for Python is installed for you automatically.

If you are not developing Apify Actors and you just need to access the Apify API from Python,
consider using the [Apify API client for Python](/api/client/python) directly.

## Adding dependencies

First, add the dependencies in the [`requirements.txt`](https://pip.pypa.io/en/stable/reference/requirements-file-format/) file in the Actor source folder.

Then activate the virtual environment in `.venv`:

<Tabs groupId="operating-systems">
    <TabItem value="unix" label="Linux / macOS" default>
        <CodeBlock language="bash">{
`source .venv/bin/activate`
        }</CodeBlock>
    </TabItem>
    <TabItem value="win" label="Windows">
        <CodeBlock language="powershell">{
`.venv\\Scripts\\activate`
        }</CodeBlock>
    </TabItem>
</Tabs>

Finally, install the dependencies:

```bash
python -m pip install -r requirements.txt
```
