# nette/latte

☕ Latte: the safest & truly intuitive templates for PHP. Engine for those who want the most secure PHP sites.

Repository: https://github.com/nette/latte
Canonical: https://ross.abutalabs.com/products/nette-latte
Homepage: https://latte.nette.org
Language: PHP
License: NOASSERTION
License Family: other
Topics: nette, nette-framework, latte, php, template-engine, xss, security, content-aware, safety, security-hole, html
Last push: 2026-07-31T18:01:34+00:00

## Health v2 (maintenance only)
Score: 96/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 95, release rhythm 95, longevity 100
- inputs: {"age_days": 5187, "days_push": 33, "days_rel": 37, "gap_med": 26, "n_releases_24m": 14}
- flags: no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1290, forks 112 (observed 2026-08-28T04:04:15.455385+00:00)

## What it is
Latte is a secure, intuitive templating engine for PHP featuring context-sensitive escaping that automatically protects against XSS vulnerabilities. It uses PHP-like syntax, compiles templates for speed, and includes sandboxing and template inheritance.

## Use cases
- render html templates in php safely
- prevent xss vulnerabilities in web pages
- separate presentation logic from application code
- migrate from twig or plain php templates
- sandbox user-edited templates
- reuse layout structures with template inheritance

## When to choose
- you need the strongest automatic XSS protection in a PHP templating engine
- you want PHP-like syntax so developers don't learn a new template language
- you need to render untrusted user-authored templates in a sandbox
- you're building on the Nette framework

## When to avoid
- your project is not written in PHP
- you're already standardized on Twig or Blade with no security pain points
- you need a JavaScript or client-side templating solution

## Facets
- artifact type: library
- maturity: stable
- function: templating, web-framework, security
- domain: web-development, security, frontend
- platform: php
- tags: template-engine, xss-protection, context-sensitive-escaping, nette-framework, sandboxing, web-server

## Member repositories
- nette/latte (main) score 96

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:15.455385+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:55:40.148779+00:00, confidence not recorded.
  - readme: https://github.com/nette/latte (fetched 2026-08-28T04:04:15.455385+00:00, sha c50cd21e63a0)
  - homepage: https://latte.nette.org (fetched 2026-08-29T12:11:54.279314+00:00, sha df0e0ab55357)
  - site_page: https://latte.nette.org/en/guide (fetched 2026-08-29T12:11:54.282122+00:00, sha dd53bf1c93af)
  - site_page: https://blog.nette.org/en/five-new-features-in-latte-3-1-that-will-make-your-life-easier (fetched 2026-08-29T12:11:54.286154+00:00, sha 69d90445fc63)
  - site_page: https://latte.nette.org/en/syntax (fetched 2026-08-29T12:11:54.284153+00:00, sha 17ce5b4fe55b)
  - site_page: https://nette.org/en/releases (fetched 2026-08-29T12:11:54.288317+00:00, sha aa39e1b5cbb1)
  - site_page: https://doc.nette.org (fetched 2026-08-29T12:11:54.294516+00:00, sha b052116b2a14)
  - site_page: https://nette.org/en/history (fetched 2026-08-29T12:11:54.296516+00:00, sha 286192274b00)
- Data as of 2026-08-30T08:39:29.467469+00:00.
