A wiki of your own
Install MediaWiki for practice: requirements and steps
To install MediaWiki you need a web server, PHP and a database. The current release, 1.46.2, needs PHP 8.3.0 or newer and works best with MariaDB; the long-term support branch is 1.43. On your own copy you hold every right, so nothing is off limits.
On this page
Which version to install (October 2026)
For practice, install the current stable release: it matches what most wikis are moving to. Choose the long-term support branch only if you must run on an older PHP.
| Branch | Latest release | Status | Supported until |
|---|---|---|---|
| 1.47 (LTS) | — | Due November 2026 | November 2029 |
| 1.46 | 1.46.2 | Current stable, released 30 June 2026 | July 2027 |
| 1.45 | 1.45.6 | Legacy stable | December 2026 |
| 1.44 | 1.44.6 | Obsolete | Ended 31 July 2026 |
| 1.43 (LTS) | 1.43.11 | Long-term support | December 2027 |
What MediaWiki 1.46 needs
- A web server, such as Apache.
- PHP 8.3.0 or later with the ctype, dom, fileinfo, iconv, intl, mbstring and xml extensions. The 1.43 LTS branch accepts PHP 8.1.0 or later.
- A database: MariaDB 10.3 or higher is recommended; MySQL 5.7.0, PostgreSQL 10 and SQLite 3.8.0 or later also work, though their support is described as less mature. SQLite needs no database server at all.
| System | PHP in its packages | MediaWiki 1.46 |
|---|---|---|
| Ubuntu 24.04 LTS | 8.3 | Yes |
| Debian 13 | 8.4 | Yes |
| Debian 12 | 8.2 | No: use 1.43 LTS, or upgrade the system |
| Ubuntu 22.04 LTS | 8.1 | No: use 1.43 LTS, or upgrade the system |
Installing on Debian or Ubuntu
These steps follow mediawiki.org's manual for Debian and Ubuntu, with the stable release of October 2026. Run them as a user with sudo rights.
- Update the system: sudo apt update && sudo apt upgrade.
- Install Apache, MariaDB and PHP: sudo apt-get install apache2 mariadb-server php php-mysql libapache2-mod-php php-xml php-mbstring. Add php-intl, which MediaWiki 1.46 lists as required, and php-apcu for caching.
- Download and unpack the release: wget https://releases.wikimedia.org/mediawiki/1.46/mediawiki-1.46.2.tar.gz, then tar -xvzf mediawiki-1.46.2.tar.gz.
- Move it into place with sudo mv mediawiki-1.46.2 /var/lib/mediawiki, and link it into the web root with sudo ln -s /var/lib/mediawiki /var/www/html/mediawiki.
- In MariaDB (sudo mysql -u root -p), create a database with CREATE DATABASE my_wiki;, create a user with a strong password, and grant that user all privileges on my_wiki.
- Open http://localhost/mediawiki in a browser and follow the installer. Watch its Checking environment step: it names any missing piece.
- At the end the installer offers a LocalSettings.php file to download. Save it in /var/lib/mediawiki; the wiki works from that moment.
Your first account is already an admin The administrator account you create in the installer can do everything: delete, protect, block, grant rights and edit the interface. Practise with it, and make a second, ordinary account to see what other users see.
On Windows or macOS, or without a server
- All-in-one bundles. XAMPP or MAMP put a web server, PHP and a database in one download. Check the bundled PHP before you start: in May 2025 XAMPP shipped PHP 8.2, enough for the 1.43 LTS branch but not for 1.46.
- A quicker local setup. mediawiki.org's Local development quickstart sets up a wiki for development with less configuration than a full server.
- A hosted wiki. A wiki farm runs the server for you, and mediawiki.org keeps a list of hosting services. You become administrator of your own wiki, but usually cannot change the server's settings or add extensions of your choosing. For trying the tools only, admin test wikis need no setup at all.
What to practise on your own wiki
- Settings. Every option lives in LocalSettings.php. Change one, reload, and see what it does.
- Extensions. Some come bundled with the download; switch one on with wfLoadExtension( 'Name' ); in LocalSettings.php. Scribunto, for Lua modules, is one of them.
- Templates. Import or write templates and test them with sandbox and test-case pages, just as on Wikipedia.
- Upgrades. Back up the database and files first, put the new release's files in place, then run the update script (php maintenance/run.php update).
Keep a public practice wiki up to date A wiki reachable from the internet needs security releases. mediawiki.org advises every wiki operator to subscribe to the mediawiki-announce mailing list and run the newest version they can. A wiki that runs only on your own computer carries much less risk.
Frequently asked questions
What do I need to install MediaWiki?
A web server, PHP and a database. MediaWiki 1.46 needs PHP 8.3.0 or later; MariaDB is the recommended database, and SQLite works without a database server.
Which MediaWiki version should I install in 2026?
The current stable release, 1.46.2 in October 2026. If your system only has PHP 8.1 or 8.2, use the long-term support branch 1.43 (1.43.11), supported until December 2027.
Can I install MediaWiki on my own computer?
Yes. On Linux install Apache, MariaDB and PHP from the package manager; on Windows or macOS use a bundle such as XAMPP or MAMP with a new enough PHP.
Am I an administrator on a wiki I install?
Yes. The account you create during installation holds administrator and bureaucrat rights, so you can practise every tool and grant rights to other accounts.
Keep reading
- Admin test wikis: where to practise the sysop toolsAdmin test wikis give out sysop rights so you can practise deleting, protecting and blocking. Four public options, their rules and versions in October 2026.
- Lua modules on MediaWiki: Scribunto, #invoke and safe testingLua modules power advanced MediaWiki templates through Scribunto. How #invoke works, a first module, the debug console, unit tests and Scribunto on your wiki.
- Template sandbox and test cases: change a template safelyHow a template sandbox and /testcases page work on Wikipedia: create both, sync them, compare old and new output, and test what a testcases page cannot show.
Wiki Practice Guide is an independent guide. It is not run by or affiliated with the Wikimedia Foundation, Wikipedia, MediaWiki.org, any test wiki it describes (including The Test Wiki, once hosted at wiki.xyrael.net) or any previous owner of this domain.