# starlette.formparsers.MultiPartException: Missing boundary in multipart.

- **ID:** `python/starlette-missing-boundary-multipart`
- **Domain:** python
- **Category:** network_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

A multipart/form-data request lacks the boundary parameter in its Content-Type header, or the client sends a body without the header.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 3.x | active | — | — |

## Workarounds

1. **** (95% success)
   ```
   import requests
files = {'file': open('a.png', 'rb')}
requests.post(url, files=files)
   ```
2. **** (92% success)
   ```
   from fastapi import File, UploadFile
@app.post('/upload')
async def upload(file: UploadFile = File(...)):
    ...
   ```

## Dead Ends

- **** — The endpoint expects form fields and fails validation. (80% fail)
- **** — Does not fix the client; uploads keep failing. (70% fail)
