---
title: Installation
description: 'For model serving support:'
canonical: 'https://lightning.ai/docs/sdk/stable/install'
---
# Installation {#installation}

## Requirements {#requirements}

- Python 3.8 or later
- A [Lightning AI](https://lightning.ai) account

## Install {#install}

Install from PyPI:

```bash
pip install lightning-sdk
```

For model serving support:

```bash
pip install "lightning-sdk[serve]"
```

## Authentication {#authentication}

Log in via the CLI before using the SDK:

```bash
lightning login
```

This stores credentials locally and is required for all API calls.
You can also set the `LIGHTNING_API_KEY` environment variable to authenticate
non-interactively in CI or headless environments.

---

**Navigation**

- Parent: [Lightning SDK](/docs/sdk/2026.11.04.md)
