fisharebest / webtrees
webtrees online genealogy
Requires
- php: 8.3 - 8.6
- ext-ctype: *
- ext-curl: *
- ext-gd: *
- ext-iconv: *
- ext-intl: *
- ext-json: *
- ext-mbstring: *
- ext-pcre: *
- ext-pdo: *
- ext-session: *
- ext-xml: *
- aura/router: 3.4.2
- ezyang/htmlpurifier: 4.19.0
- fig/http-message-util: 1.1.5
- fisharebest/algorithm: 1.6.0
- fisharebest/ext-calendar: 2.6.0
- fisharebest/localization: 1.17.0
- guzzlehttp/guzzle: 7.10.0
- illuminate/database: 12.58.0
- illuminate/support: 12.58.0
- intervention/image: 3.11.7
- league/commonmark: 2.8.2
- league/flysystem: 3.33.0
- league/flysystem-path-prefixing: 3.31.0
- league/flysystem-ziparchive: 3.31.0
- middlewares/client-ip: 2.1.0
- mlocati/ip-lib: 1.22.0
- nesbot/carbon: 3.11.4
- nyholm/psr7: 1.8.2
- nyholm/psr7-server: 1.1.0
- psr/cache: 3.0.0
- psr/http-message: 2.0
- psr/http-server-handler: 1.0.2
- psr/http-server-middleware: 1.0.2
- ramsey/uuid: 4.9.2
- sabre/vobject: 4.5.8
- symfony/cache: 7.4.8
- symfony/console: 7.4.8
- symfony/expression-language: 7.4.8
- symfony/mailer: 7.4.8
- symfony/polyfill-mbstring: 1.37.0
- tecnickcom/tcpdf: 6.11.3
Requires (Dev)
- ext-dom: *
- ext-libxml: *
- ext-pdo_sqlite: *
- ext-sqlite3: *
- league/flysystem-memory: 3.31.0
- php-coveralls/php-coveralls: 2.9.1
- phpstan/extension-installer: 1.4.3
- phpstan/phpstan: 2.1.51
- phpstan/phpstan-deprecation-rules: 2.0.4
- phpstan/phpstan-phpunit: 2.0.16
- phpunit/phpunit: 12.5.23
- squizlabs/php_codesniffer: 4.0.1
Suggests
- ext-imagick: Required to generate thumbnail images
- ext-pdo_mysql: Required to use MySQL for database storage
- ext-pdo_pgsql: Required to use PostgreSQL for database storage
- ext-pdo_sqlite: Required to use SQLite for database storage
- ext-pdo_sqlsrv: Required to use SQL Server for database storage
- ext-zip: Required to compress downloads and use the upgrade wizard
- ext-zlib: Required to compress HTTP responses
This package is auto-updated.
Last update: 2026-08-05 16:22:12 UTC
README
webtrees — online collaborative genealogy
webtrees is a web application for recording, viewing and sharing your family history. It imports and exports standard GEDCOM files, making it compatible with every major desktop genealogy application.
You host it on your own web server, so you stay in control of your data. Multiple family members can collaborate on the same tree at the same time, and you decide who can see what through fine-grained privacy rules.
Key features:
- Full editing of individuals, families, sources, media and other GEDCOM records
- Interactive charts — pedigree, fan, descendants, relationships
- Privacy controls per record, per user, per tree
- Multi-language interface (70+ translations)
- Theming support with several built-in themes
- Module system for extending functionality
- Multiple family trees in one installation
For user documentation, screenshots and demos visit https://webtrees.net/.
This software is licensed under the GNU General Public License v3 or later. See LICENSE.md for the full text.
Getting started
Download
Download the latest stable release from github.com/fisharebest/webtrees/releases/latest.
Server requirements
| Component | Requirement |
|---|---|
| PHP | 8.3 – 8.6 |
| Database | MySQL (recommended), PostgreSQL, SQLite, or SQL Server |
| Web server | Apache, NGINX, IIS or similar (URL rewriting needed for pretty URLs) |
| Disk space | ~100 MB for application files, plus space for media and database |
Required PHP extensions: ctype, curl, gd, iconv, intl, json, mbstring,
pcre, pdo, session, xml.
Recommended PHP extensions: exif (auto-rotate images), zip (compress downloads
and use the upgrade wizard), zlib (compress HTTP responses).
PHP memory and execution time should be scaled to your tree size:
| Tree size | Memory | Max execution time |
|---|---|---|
| Small (500 individuals) | 16–32 MB | 10–20 s |
| Medium (5 000 individuals) | 32–64 MB | 20–40 s |
| Large (50 000 individuals) | 64–128 MB | 40–80 s |
Installation
- Upload and extract the release archive to an empty folder on your web server.
- Navigate to the URL in your browser — the setup wizard starts automatically.
- Create your first family tree and optionally import a GEDCOM file.
Full installation and upgrade guides are available at https://webtrees.net/.
Technical architecture
Project structure
app/ Application source (PSR-4 root: Fisharebest\Webtrees\)
├── Cli/Commands/ CLI commands (extend AbstractCommand)
├── Contracts/ Interfaces (*Interface suffix)
├── Enums/ PHP enumerations
├── Factories/ Object creation (Registry pattern)
├── Http/
│ ├── RequestHandlers/ HTTP controllers (one class per route action)
│ ├── Middleware/ HTTP controllers (one class per route action)
│ └── Routes/ Route definitions
├── Module/ Modules (charts, reports, sidebars, tabs, themes…)
├── Services/ Domain services
└── … Domain classes (Individual, Family, Tree, etc.)
resources/
├── css/ Stylesheets (compiled by webpack)
├── js/ JavaScript (compiled by webpack)
├── lang/ Language files (*.po, compiled into *.php for release)
└── views/ View templates (*.phtml)
tests/
├── Unit/ Unit tests
└── Feature/ Feature/integration tests
public/ Web-accessible assets (compiled CSS/JS, images, fonts)
data/ Runtime data (config, GEDCOM files, cache — not in VCS)
modules_v4/ Third-party module directory
Namespace and autoloading
| Namespace | Directory | Standard |
|---|---|---|
Fisharebest\Webtrees\ |
app/ |
PSR-4 |
Fisharebest\Webtrees\Tests\ |
tests/ |
PSR-4 |
Global helper functions are in app/Helpers/functions.php (loaded via composer
autoload.files).
Coding standards
webtrees follows PSR-12 with these additional rules:
- Abstract classes are named
Abstract*. - Interfaces are named
*Interface. - Traits are named
*Trait. - Local variables and parameters use
$snake_case. - Nullable types are written
Type|null, not?Type. - PHP function/constant calls never use named arguments.
- Variable names are full English words (
$variables, not$vars). - Comments and identifiers use US English (
$color, not$colour). - All PHP functions and constants are imported with
use; unused imports are removed. - No two consecutive blank lines.
- Unit test method names are
camelCase, notsnake_case.
For javascript, we use semistandard.
PSR standards applied:
| PSR | Topic |
|---|---|
| PSR-4 | Autoloading |
| PSR-6 | Caching |
| PSR-7 | HTTP messages |
| PSR-11 | Dependency injection container |
| PSR-12 | Coding style |
| PSR-15 | HTTP request handlers and middleware |
| PSR-17 | HTTP factories |
| PSR-18 | HTTP client |
Dependencies
All dependencies are pinned to exact version numbers (no ranges).
Main PHP dependencies (via Composer):
illuminate/databasesymfony/cache,symfony/console,symfony/mailer,symfony/http-clientleague/flysystemleague/commonmarkaura/router
Main JavaScript dependencies (via npm / webpack):
- Bootstrap 5
- Font Awesome
- LeafletJs
- DataTables
- Chart.js, Tom Select, Sortable.js
Building from source
Prerequisites: PHP 8.3+, Composer, Node.js with npm.
# Install PHP dependencies composer install # Install JS dependencies and compile assets npm install npm run build # Create a .ZIP file containing a release composer build
Quality and CI
Run the full local CI suite:
composer ci
This executes, in order:
| Tool | Purpose | Config file |
|---|---|---|
| PHP_CodeSniffer | PSR-12 style enforcement | phpcs.xml.dist |
| PHPUnit | Unit and feature tests | phpunit.xml.dist |
| PHPStan (level 6) | Static analysis | phpstan.neon.dist |
Individual commands:
# Coding style (fix automatically) vendor/bin/phpcbf # Tests with coverage vendor/bin/phpunit # Static analysis vendor/bin/phpstan
Testing
Tests live in tests/Unit/ and tests/Feature/. Run a subset with:
vendor/bin/phpunit --filter=testMethodName vendor/bin/phpunit tests/Feature/SomeTest.php
HTTP architecture
The application uses PSR-15 middleware and request handlers:
index.phpboots the application and dispatches the request.- Routes are defined declaratively in
app/Http/Routes/. - Each route maps to a request handler in
app/Http/RequestHandlers/. - Middleware provides cross-cutting concerns (authentication, CSRF, etc.).
Module system
Most user-visible features are implemented as modules in app/Module/. Modules
implement one or more interfaces (e.g. ModuleChartInterface,
ModuleReportInterface, ModuleThemeInterface) and are auto-discovered by the
ModuleService.
Third-party modules can be placed in modules_v4/.
Database
webtrees uses Laravel’s Illuminate Database (query builder and schema builder) without the full Laravel framework. Supported drivers:
- MySQL / MariaDB
- SQLite
- PostgreSQL
- SQL Server
Schema migrations are in app/Schema/. The current schema version is tracked in
app/Webtrees.php.
Table names use a configurable prefix so multiple instances can share a database.