# doctrine/orm

Doctrine Object Relational Mapper (ORM)

Repository: https://github.com/doctrine/orm
Canonical: https://ross.abutalabs.com/products/orm
Homepage: https://www.doctrine-project.org/projects/orm.html
Language: PHP
License: MIT
License Family: permissive
Topics: hacktoberfest
Last push: 2026-08-26T05:39:48+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 96, longevity 100
- inputs: {"age_days": 5993, "days_push": 7, "days_rel": 28, "gap_med": 1, "n_releases_24m": 44}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 10169, forks 2540 (observed 2026-08-28T04:10:39.735035+00:00)

## What it is
Doctrine ORM is an object-relational mapper for PHP 8.1+ that provides transparent persistence for PHP objects on top of the Doctrine DBAL database abstraction layer. It lets developers query databases using Doctrine Query Language (DQL), an object-oriented SQL dialect inspired by Hibernate's HQL.

## Use cases
- map PHP objects to database tables
- write database queries with an object-oriented query language
- manage entity relationships and associations in PHP
- persist and retrieve domain entities transparently
- build a Symfony or Laminas application with a mature ORM
- replace raw SQL with a query builder and DQL

## When to choose
- you are building a PHP application that needs robust, battle-tested object persistence
- you want rich association mapping, inheritance mapping, and event system support
- you prefer DQL/QueryBuilder over hand-written SQL
- you need a widely adopted ORM with extensive documentation and community support

## When to avoid
- you want a lightweight query builder without full entity management overhead
- your project uses PHP below 8.1
- you need extremely raw, hand-tuned SQL control for every query
- you are working outside the PHP ecosystem

## Facets
- artifact type: library
- maturity: stable
- function: orm, database, database-driver, caching
- domain: databases, web-development, backend, developer-tools
- platform: php, cross-platform
- tags: doctrine, dql, query-builder, entity-mapping, persistence, dbal, symfony

## Member repositories
- doctrine/orm (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:39.735035+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-29T17:19:39.695145+00:00, confidence not recorded.
  - readme: https://github.com/doctrine/orm (fetched 2026-08-28T04:10:39.735035+00:00, sha a1562762318b)
  - homepage: https://www.doctrine-project.org/projects/orm.html (fetched 2026-08-29T08:19:22.801006+00:00, sha 2af89fcfe2dd)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/3.6/index.html (fetched 2026-08-29T08:19:22.810752+00:00, sha 034b67741c3c)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/latest/index.html (fetched 2026-08-29T08:19:22.812852+00:00, sha 9f8c734f30c2)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/3.7/index.html (fetched 2026-08-29T08:19:22.814595+00:00, sha 03211c6c7ba9)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/2.21/index.html (fetched 2026-08-29T08:19:22.816340+00:00, sha 970ffab9c2bb)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/2.20/index.html (fetched 2026-08-29T08:19:22.817939+00:00, sha 2fa60d414d98)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/2.19/index.html (fetched 2026-08-29T08:19:22.819556+00:00, sha 739c8d6cbe9e)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/2.18/index.html (fetched 2026-08-29T08:19:22.821147+00:00, sha c8db3f33ef47)
  - site_page: https://www.doctrine-project.org/projects/doctrine-orm/en/2.17/index.html (fetched 2026-08-29T08:19:22.822791+00:00, sha 7240ce69dd10)
- Data as of 2026-08-30T08:39:29.467469+00:00.
