# Doctrine vs Ecto

**Leader by Vioscale score:** Doctrine

| Attribute | Doctrine | Ecto |
|---|---|---|
| **Vioscale score** | 67.2 (54% (medium)) | 51.9 (39% (low)) |
| activity.commits_last_30d | 10 | 12 |
| adoption.dependent_repos | 87,805 | 12,249 |
| adoption.github_stars | 10,169 | 6,487 |
| deployment.options | `{"self_hosted":true}` | - |
| description.long | Doctrine provides PHP developers with both high-level object-oriented database tools and low-level direct SQL access. The core includes an Object Relational Mapper for complex data modeling and a Database Abstraction Layer for flexible database interaction. | A library that enables type-safe database queries and schema mapping for Elixir, supporting multiple database backends including PostgreSQL, MySQL, and SQLite with language-integrated querying. |
| features.capabilities | `{"raw_sql":true,"multi_db":true,"languages":"PHP","relations":true,"migrations":true}` | `{"multi_db":true,"languages":"Elixir","relations":true,"schema_first":true,"type_safe_queries":true}` |
| integrations.count | 20 | 6 |
| integrations.list | `[{"name":"Symfony"},{"name":"Drupal"},{"name":"Laravel"},{"name":"Laminas"},{"name":"API Platform"},{"name":"eZ Platform"},{"name":"Akeneo PIM"},{"name":"Pimcore"},{"name":"Sylius"},{"name":"Shopware"},{"name":"Contao"},{"name":"Oxid eShop"},{"name":"PrestaShop"},{"name":"TYPO3"},{"name":"Sonata Project"},{"name":"JMS Libraries"},{"name":"Go! AOP"},{"name":"KNP Labs"},{"name":"PHPUnit"},{"name":"phpbench"}]` | `[{"name":"PostgreSQL"},{"name":"MySQL"},{"name":"MSSQL"},{"name":"SQLite3"},{"name":"ClickHouse"},{"name":"ETS"}]` |
| language.primary | PHP | Elixir |
| license.spdx | MIT | Apache-2.0 |
| market.availability | `{"primaryMarkets":[],"availabilityScope":"global","availableCountries":[],"notAvailableCountries":[]}` | - |
| platform.support | `{"cli":true,"web":true}` | - |
| pricing | `{"type":"open_source","freeTier":true,"sourceUrl":"https://www.doctrine-project.org/","retrievedAt":"2026-08-14T08:35:07.074Z"}` | `{"type":"open_source","sourceUrl":"https://hexdocs.pm/ecto","retrievedAt":"2026-08-14T08:32:02.160Z"}` |
| pricing.free_tier | yes | - |
| pricing.model | commercial | open_source |
| pricing.price_level | free | free |
| pricing.transparent | yes | - |
| release.cadence_days | 2 | - |
| release.history | `[{"url":"https://github.com/doctrine/orm/releases/tag/3.6.8","date":"2026-08-05T19:06:31Z","type":"stable","version":"3.6.8"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.7","date":"2026-05-25T16:53:47Z","type":"stable","version":"3.6.7"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.13","date":"2026-05-25T16:47:26Z","type":"stable","version":"2.20.13"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.6","date":"2026-05-21T06:09:26Z","type":"stable","version":"3.6.6"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.5","date":"2026-05-11T06:48:56Z","type":"stable","version":"3.6.5"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.12","date":"2026-05-08T11:19:50Z","type":"stable","version":"2.20.12"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.4","date":"2026-05-07T20:22:28Z","type":"stable","version":"3.6.4"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.11","date":"2026-05-07T20:18:17Z","type":"stable","version":"2.20.11"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.3","date":"2026-04-02T06:54:32Z","type":"stable","version":"3.6.3"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.10","date":"2026-04-02T06:20:37Z","type":"stable","version":"2.20.10"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.2","date":"2026-01-30T21:43:07Z","type":"stable","version":"3.6.2"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.1","date":"2026-01-09T06:44:11Z","type":"stable","version":"3.6.1"},{"url":"https://github.com/doctrine/orm/releases/tag/3.6.0","date":"2025-12-19T20:41:15Z","type":"stable","version":"3.6.0"},{"url":"https://github.com/doctrine/orm/releases/tag/3.5.8","date":"2025-11-29T23:12:27Z","type":"stable","version":"3.5.8"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.9","date":"2025-11-29T23:12:35Z","type":"stable","version":"2.20.9"},{"url":"https://github.com/doctrine/orm/releases/tag/3.5.7","date":"2025-11-11T18:29:24Z","type":"stable","version":"3.5.7"},{"url":"https://github.com/doctrine/orm/releases/tag/3.5.6","date":"2025-11-10T21:12:30Z","type":"stable","version":"3.5.6"},{"url":"https://github.com/doctrine/orm/releases/tag/3.5.5","date":"2025-11-10T20:27:08Z","type":"stable","version":"3.5.5"},{"url":"https://github.com/doctrine/orm/releases/tag/3.5.4","date":"2025-11-10T20:23:35Z","type":"stable","version":"3.5.4"},{"url":"https://github.com/doctrine/orm/releases/tag/2.20.8","date":"2025-11-10T20:24:32Z","type":"stable","version":"2.20.8"}]` | `[{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v3.4.5","date":"2020-07-28T19:18:20Z","type":"stable","version":"v3.4.5"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v2.2.0-rc.1","date":"2017-08-18T13:36:53Z","type":"prerelease","version":"v2.2.0-rc.1"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v2.0.1","date":"2016-06-21T13:18:18Z","type":"stable","version":"v2.0.1"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v2.0.0","date":"2016-06-21T13:18:36Z","type":"stable","version":"v2.0.0"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.8","date":"2016-06-21T13:19:18Z","type":"stable","version":"v1.1.8"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.7","date":"2016-06-21T13:19:35Z","type":"stable","version":"v1.1.7"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.6","date":"2016-06-21T13:19:58Z","type":"stable","version":"v1.1.6"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.5","date":"2016-04-19T10:08:50Z","type":"stable","version":"v1.1.5"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.4","date":"2016-04-19T10:08:36Z","type":"stable","version":"v1.1.4"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.3","date":"2016-02-22T10:46:14Z","type":"stable","version":"v1.1.3"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.2","date":"2016-02-22T10:46:01Z","type":"stable","version":"v1.1.2"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.1","date":"2015-12-23T15:32:10Z","type":"stable","version":"v1.1.1"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.1.0","date":"2015-12-23T15:31:55Z","type":"stable","version":"v1.1.0"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.7","date":"2015-12-23T15:34:06Z","type":"stable","version":"v1.0.7"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.6","date":"2015-12-23T15:33:53Z","type":"stable","version":"v1.0.6"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.5","date":"2015-12-23T15:33:36Z","type":"stable","version":"v1.0.5"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.4","date":"2015-12-23T15:33:16Z","type":"stable","version":"v1.0.4"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.3","date":"2015-12-23T15:32:50Z","type":"stable","version":"v1.0.3"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.2","date":"2015-09-07T13:16:29Z","type":"stable","version":"v1.0.2"},{"url":"https://github.com/elixir-ecto/ecto/releases/tag/v1.0.1","date":"2015-08-30T09:10:09Z","type":"stable","version":"v1.0.1"}]` |
| reliability.status_page | - | yes |
| security.scorecard | 6.9 | 5.7 |
| security.vulnerabilities | `{"count":3,"source":"https://advisories.ecosyste.ms/api/v1/advisories?ecosystem=packagist&package_name=doctrine%2Form&per_page=100","last_12m":0,"max_severity":"CRITICAL"}` | `{"count":2,"source":"https://advisories.ecosyste.ms/api/v1/advisories?ecosystem=hex&package_name=ecto&per_page=100","last_12m":0,"max_severity":"CRITICAL"}` |

## Capabilities (ORM & Database Tools)

| Capability | Doctrine | Ecto |
|---|:--:|:--:|
| **Core** |  |  |
| Type-safe queries | - | ✓ |
| Schema migrations | ✓ | - |
| Relations / joins API | ✓ | ✓ |
| Languages | PHP | Elixir |
| **Modelling** |  |  |
| Schema-first modelling | - | ✓ |
| **Flexibility** |  |  |
| Raw SQL escape hatch | ✓ | - |
| **Portability** |  |  |
| Multiple database backends | ✓ | ✓ |
| **Ops** |  |  |
| Connection pooling | - | - |
| **DX** |  |  |
| Data browser / studio | - | - |

*Source: Vioscale. Generated 2026-09-01T17:23:56.389Z. "-" = undocumented, not absent.*
