# jinja2.exceptions.TemplateNotFound: index.html

- **ID:** `python/flask-jinja2-template-not-found`
- **Domain:** python
- **Category:** config_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

The template file is not in the configured `templates/` folder relative to the app root, or the app was created with the wrong `root_path`.

## Version Compatibility

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

## Workarounds

1. **** (97% success)
   ```
   project/
  app.py
  templates/index.html
app = Flask(__name__, template_folder='templates')
   ```
2. **** (85% success)
   ```
   app.jinja_loader.searchpath.append('/abs/path/templates')
   ```

## Dead Ends

- **** — Bypasses loader but loses autoescape/extends; brittle path handling. (70% fail)
- **** — Reload flag only affects change detection, not lookup. (90% fail)
