Redesign the php.net homepage by mattstauffer · Pull Request #2105 · php/web-php

· GitHub

9 min read Original article ↗

A new php.net homepage

Preview here: https://web-php-pr-2105.preview.thephp.foundation/

Discussion period: At least two weeks; no merge until at earliest December 4, 2026.

What is it?
This PR replaces the php.net homepage with a new design. It's the result of several months of open discussion in the PHP Ambassadors marketing group.

image

This PR's plans, priorities, and design have been evaluated and considered pretty extensively, but I'd especially love eyes on the code implementation, especially on these two areas:

  1. The code examples. Are these the examples that would be most compelling and helpful to someone new to PHP? Ideas for better ones are very welcome. (More on this below.)
  2. The implementation. There's a lot of code here, and I'd appreciate more people reading through it.

Why now

The current php.net design launched in 2014 (2013, 2014). That's twelve years ago! PHP itself has changed enormously since then, but the front door to the language still looks the way it did before PHP 7 existed, and today the homepage is mostly a release log.

That matters because many developers still think of PHP the way it was a decade or two ago, and php.net is often the first place they check. In one of the Ambassadors group meetings, this line stuck with me:

"The sustainability of the language is dependent on our ability to convince, and often re-convince, people that PHP is a viable language to use today."

php.net isn't the only place that work happens, but it's the one place every PHP developer--and, more importantly when convincing people PHP is viable--every curious/concerned newcomer will eventually land. Our homepage should show the language as it is today.

How we got here

This was all done in the open, and anyone has been welcome (and invited!) to join in at any point.

  • July: #1962 opened as a first draft of a new front page, built on Mark Randall's work. The discussion there produced a proposed goal, audiences, and list of "jobs" for a new attempt at redesigning the homepage.
  • July onward: The PHP Ambassadors group formed a marketing subgroup that meets monthly. The meetings are open to anyone, and the notes are public: meeting notes. Discussion continues between meetings in the #marketing channel on the PHPC Discord (it's a public server; you'll need to join to see the channel).
  • August: We agreed on the homepage's goal and audiences, and voted on which content was a must-have, a nice-to-have, or out of scope.
  • September: We worked through personas: developers new to PHP, developers coming back to it, and decision-makers at companies, governments, and schools. We talked through what each of them needs to see.
  • October: Jack McDade of Radical Design delivered a design based on that content plan. We reviewed it in the October meeting against everything we'd agreed on and came away with a list of changes.
  • November: I built it, worked through that list, and brought it back to the group. We agreed to ship it as one PR with a two-week discussion period, which is what you're looking at.

We're making it as a PR because the history of previous redesigns on PHP.net have been like this: a group of people openly plan a redesign, they present it for review, and then they merge it in.

Why a PR and not an RFC?

PHP's RFC process is for changes to the language, and php.net's past redesigns haven't gone through it. They followed the path this one has: a group plans the redesign in the open, presents it for review, and merges it once the feedback has been worked through. Derick helped make sure we followed that precedent here. This PR and its two-week discussion period are the review step, so this is the place to push back on any of it.

Who it's for

The goal we agreed on:

The php.net homepage should make a modern developer or technical decision-maker immediately understand that PHP is widely deployed, actively evolving, easy to start with, practical for real production software, and backed by a mature ecosystem and global community.

In priority order, the audiences are:

  1. Developers evaluating or re-evaluating PHP. Many of them have an outdated impression of the language.
  2. Technical decision-makers. CTOs, engineering leads, educators, and others who decide whether a team or a class uses PHP.
  3. Existing PHP developers. That's most of us, and we still need fast paths to downloads, docs, releases, and migration guides

Putting existing developers third was deliberate. We're the audience that already knows our way around php.net and is most willing to take an extra click to get somewhere. Newcomers and decision-makers often get one look before deciding PHP isn't worth their time.

In practice, the extra click is small. The hero still has "Download PHP" and a "Latest releases" panel with every supported version and its changelog and upgrade links, plus the latest news. The footer keeps the utility links. And if you really just want the old homepage, it's still there at /classic/. It's hidden from search engines but available to anyone who wants it.

The design

This isn't a net-new visual identity. We deliberately built it as a continuation of what already exists:

  • The current php.net design, with the same color palette and overall feel.
  • The PHP 8.x release pages, which are the most recent design work on the site and where the community has already accepted a more modern look. The homepage uses the same visual language, and this PR moves the release pages onto the same shared style sheets and JavaScript so the two stay consistent going forward.

The homepage is made up of these sections:

  • Hero: positioning, Get started / Download / News and Releases
  • Logo wall: well-known organizations with a public, sourced connection to PHP (sources below)
  • Everything the web needs: what PHP is for today, plus the code examples
  • A package for almost everything: Composer, Packagist (with live stats), and PIE
  • Still moving: the newest release and its highlights
  • Built by people: how the language is developed, and funding the people who work on it
  • Get started: set up, learn the language, explore packages
  • PHP through the years: a timeline of every release since 1995

Out of scope for now

A few things came up that we decided to leave for later PRs, so they get their own conversations:

  • A section on frameworks and projects built with PHP. The ecosystem is one of PHP's strongest selling points, but picking which to feature requires its own separate discussion.
  • Case studies
  • A dedicated community/events page

Feedback I'm looking for

Code examples

This is the place where I'd most love help. The examples live in include/homepage/examples.php. Right now there are five:

  • UserController.php: a JSON endpoint using attributes, typed properties, and constructor injection
  • GreetCommand.php: a CLI command defined with attributes
  • release_date.php: coding against PSR interfaces with a pluggable HTTP client
  • stream_large_dataset.php: generators walking a file larger than memory
  • extract_headlines.php: fetching a page and querying it with the built-in DOM parser and CSS selectors

The question is: what would be most compelling and helpful to someone who's new to PHP, or who hasn't looked at it in years? Suggestions for replacements or additions are very welcome. Good examples are short, show off something modern about the language, and have realistic output in the terminal panel.

Implementation

Of course, I did the best I could to match this to A) the existing code style of the site, B) the future-facing code style its phpstan/etc. guidelines expect, and C) a framework-agnostic view of what modern PHP/CSS/JS looks like today. But I'm only one person and I'd love any help necessary to make sure this fits well with the current and future php.net code.

What's in the code
  • Homepage: public/index.php, with data and helpers in include/homepage.inc and include/homepage/*.php (examples, release highlights, logos, timeline overrides)
  • New classes in src/Homepage/, each with unit tests:
    • FeaturedRelease: picks the newest released branch for the "Meet PHP x.y" card, so highlights for an upcoming release can be added before release day
    • ReleaseHistory: builds the "PHP through the years" timeline
    • PackagistStats: reads Packagist totals from a JSON file written by the backend update script, with fallback values if the file is missing
  • CSS: plain CSS with no build step. It's split into base.css, components.css, homepage.css, search-modal.css, and release-page.css. php85.css became release-page.css, and the release pages now share components with the homepage. theme-medium.css is no longer used by these pages.
  • JS: small, dependency-free scripts: homepage.js (tabs, releases panel, timeline), site-header.js (theme switcher, search, mobile menu, language switcher), copy-code.js, and keyboard.js (a jQuery-free version of the keyboard easter eggs)
  • Fonts: Inter and IBM Plex Mono, self-hosted under public/fonts/
  • Shared header and footer changes in include/header.inc, include/layout.inc, include/site-header.inc, and include/footer.inc
  • Old homepage moved to public/classic/index.php, sending X-Robots-Tag: noindex
  • Compatible with PHP 8.4
Logo wall sources

Every logo needs a public, reputable connection to PHP. Here's what each one is based on. A couple of logos from earlier drafts were removed because we couldn't find a public source.

Logo Connection Source
Nike about.nike.com runs on Twill https://area17.com/clients/nike
NASA nasa.gov and NASA Science run on WordPress https://lonerockpoint.com/work/nasa-flagship-wordpress/
The New York Times Built with WordPress and Twill https://wordpress.org/showcase/the-new-york-times-company/
Zillow Aryeo, a Zillow company, is built on Laravel https://github.com/AryeoHQ
Asana Marketing website runs on Statamic https://web.archive.org/web/20250321162614/https://blog.asana.com/2014/02/scaling-asana-com/
PlayStation PlayStation Blog runs on WordPress https://wordpress.org/showcase/playstationblog/
DHL DHL eCommerce website runs on Drupal https://www.dhlecommerce.nl/en/business/knowledge-platform/dhl-blog/multiple-prizes-dhl-website
Etsy Marketplace engineering built with PHP https://careers.etsy.com/engineering
Marvel MARVEL Strike Force website runs on Twill https://twillcms.com/made
Der Spiegel Built on Statamic https://statamic.com/showcase/der-spiegel
Lemon Squeezy Built on Laravel https://www.lemonsqueezy.com/blog/lemonhead-gilbert-pellegrom
Wikipedia Built on MediaWiki, a PHP application https://www.mediawiki.org/wiki/PHP

Timeline

Comments are open for at minimum two weeks, until December 4, 2026. I'll keep updating the branch as feedback comes in. After that, unless something significant comes up, I hope for us to make the decision to merge; if further discussions is required at that point, of course we can keep it moving!

Thank you

Thanks to Jack McDade for the design, to Derick Rethans for sharing the history of designs and helping guide the process to be in line with how work has historically proceeded on php.net, to Mark Randall for the groundwork in #1962, to Roman Pronskiy and Nuno Guerra for the 8.x release page design for showing what php.net could look like, and to everyone who came to the marketing meetings, left notes, or commented on #1962.