# Hector ORM > Hector is a modern, modular and lightweight PHP ORM designed to be framework-agnostic, with decoupled components usable independently. ## Overview Hector ORM is an open-source PHP ORM (MIT license) built for simplicity, modularity and performance. It follows PSR standards (PSR-4, PSR-7, PSR-14, PSR-16) and provides schema introspection, a fluent query builder, typed data mapping, relationship management, and advanced pagination — all usable as standalone packages or together. ## Key Features - **Lightweight & Modular**: Each component (Collection, Connection, DataTypes, Query, Schema, Pagination, ORM) is a standalone package - **Framework-Agnostic**: No dependency on any specific PHP framework - **Zero-Config Entity Mapping**: Mapping derived from schema introspection, no XML/YAML files needed - **PSR Compliant**: Built on PSR-4 (Autoloading), PSR-7 (HTTP Messages), PSR-14 (Event Dispatcher), PSR-16 (Simple Cache) - **PHP 8 Attributes**: Entity configuration via native PHP attributes (Table, Primary, HasMany, BelongsTo, etc.) - **Fluent Query Builder**: Type-safe SELECT, INSERT, UPDATE, DELETE and UNION queries - **Relationships**: OneToOne, OneToMany, ManyToOne, ManyToMany with eager loading and cascade save - **Advanced Pagination**: Offset-based, cursor-based (signed/encrypted), and RFC 7233 range-based - **Read/Write Separation**: Built-in support for master/replica database setups - **DBMS Support**: MySQL 5.7–9.5+, MariaDB 10.5–12.1+, SQLite 3.x+ - **PHP Compatibility**: PHP 8.0 to 8.5+ ## Quick Start ```shell composer require hectororm/hectororm ``` ## Packages - **hectororm/collection**: Typed eager and lazy collections with full functional API - **hectororm/connection**: PDO wrapper with read/write DSN, driver introspection, query logging - **hectororm/data-types**: Bidirectional type casting (DateTime, Enum, JSON, UUID, etc.) - **hectororm/query**: Fluent query builder with sorting and pagination support - **hectororm/schema**: Runtime schema introspection (tables, columns, indexes, foreign keys) - **hectororm/pagination**: Offset, cursor and range pagination with URI builders - **hectororm/orm**: Core ORM with entities, relationships, mapper, events and storage ## Documentation - [Version 1.x](https://gethectororm.com/docs/1.x/) ## Links - Documentation: https://gethectororm.com - Source Code: https://github.com/hectororm/hectororm - Packagist: https://packagist.org/packages/hectororm/hectororm - License: MIT (https://spdx.org/licenses/MIT)