# Apps

An app is a long-running service that Flyte keeps up, rather than a job that runs to completion. Use an app when something needs to stay reachable at a URL: a dashboard, a REST API, a model endpoint, or an MCP server.

Apps are declared the same way tasks are. An `AppEnvironment` names the image, the port, and the scaling behavior, and the code inside it is an ordinary web application.

```python
app = flyte.AppEnvironment(name="dashboard", image=..., port=8080)
```

Because apps and tasks live in the same project, an app can read what a task produced without moving data between systems, and a task can call an app it depends on.

Apps scale to zero when idle, so a rarely-used dashboard costs nothing between visits.

### [Configure apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/configure-apps/page.md)

Define `AppEnvironment`s with ports, autoscaling, custom domains, and authentication.

### [Build apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/build-apps/page.md)

Build dashboards, REST APIs, and model endpoints with FastAPI, Streamlit, vLLM, and more.

### [Native app integrations](https://www.union.ai/docs/latest/flyte/user-guide/apps/native-app-integrations/page.md)

Use pre-built environments for popular frameworks like Streamlit, FastAPI, vLLM, SGLang, and Ollama.

### [Serve and deploy apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/serve-and-deploy-apps/page.md)

Use `flyte serve` for fast iteration or `flyte deploy` for production deployments.

## Related

### [Tasks](https://www.union.ai/docs/latest/flyte/user-guide/tasks/page.md)

The batch workloads an app usually serves the results of.

### [Agents](https://www.union.ai/docs/latest/flyte/user-guide/agents/page.md)

Agents are often deployed as apps so they can be reached over HTTP.

## Subpages

- [Configure apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/configure-apps/page.md)
  - Hello World example
  - Using fserve args
  - Using @app_env.server
  - Differences from TaskEnvironment
  - Configuration topics
- [Build apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/build-apps/page.md)
  - App types
  - Usage patterns
  - Next steps
- [Native app integrations](https://www.union.ai/docs/latest/flyte/user-guide/apps/native-app-integrations/page.md)
  - When to use a native integration
  - Available integrations
  - Next steps
- [Serve and deploy apps](https://www.union.ai/docs/latest/flyte/user-guide/apps/serve-and-deploy-apps/page.md)
  - Serve vs deploy
  - `flyte serve`
  - `flyte deploy`
  - Using Python SDK
  - Serve
  - Deploy
  - Using the CLI
  - Serve
  - Deploy
  - Next steps

---
**Source**: https://github.com/unionai/unionai-docs/blob/main/content/user-guide/apps/_index.md
**HTML**: https://www.union.ai/docs/latest/flyte/user-guide/apps/
