Upgrades
Upgrading RuntCMS is a two-step process: replace the application files, then run any pending database migrations. Your content is never touched.
What is safe to overwrite
Your content lives in the database and in these folders inside public_html/:
| Folder | Contents |
|---|---|
cms/pages/ | Your HTML page files |
cms/uploads/ | Uploaded images |
cms/css/ | Your CSS assets |
cms/js/ | Your JS assets |
config.php | Database credentials |
The release package does not include any of these. Overwriting everything else is safe.
Step 1 — Download and upload the new files
- Download the latest release ZIP from runtcms.com.
- Extract the ZIP on your computer.
- Upload the extracted files to your
public_html/via FTP, SFTP, or your host's file manager, overwriting existing files.
config.php — your database credentials live there. The release package does not include a config.php, so this is not normally an issue, but double-check before uploading.
Step 2 — Run database migrations
After uploading the new files, log in and visit Admin → Upgrade. If the new version includes database changes, you will see a list of pending migrations.
- Review the list of pending migrations.
- Click Run Migrations.
- RuntCMS runs each migration in order and shows the result. If one fails, it stops and displays the SQL so you can run it manually.
- Once complete, the page confirms all migrations are applied.
Running migrations manually
If the Run Migrations button fails — most commonly because your database user lacks ALTER TABLE privilege — you can run the SQL directly.
The Upgrade page shows the exact SQL for each pending migration. Copy it and run it using one of the methods below.
Via cPanel / phpMyAdmin
- Log in to cPanel and open phpMyAdmin.
- Select your RuntCMS database from the left sidebar.
- Click the SQL tab.
- Paste the SQL from the Upgrade page into the box.
- Click Go.
- Repeat for each pending migration in order.
Via SSH
mysql -u your_db_user -p your_db_name < migrations/0002_file_revisions.sql
Run each pending migration file in filename order. The filenames are numbered sequentially so the correct order is always clear.
Alternative — Clean install + snapshot restore
If you'd rather not overwrite files via FTP, or if your site is in a broken state after a previous upgrade attempt, you can upgrade using a snapshot instead.
- Log in to your existing site and go to Admin → Backups.
- Click Download Snapshot to export your content — pages, regions, images, CSS, JS, and settings are all included.
- Follow the standard installation instructions on a fresh database: upload the new release package and visit
/install.php. - Once installed, go to Admin → Backups and import the snapshot you downloaded in step 2.
Migration history
The Upgrade page shows a collapsible list of all previously applied migrations. Use this to confirm which database version your site is running — useful when reporting a bug or asking for support.
Troubleshooting
The site shows a white screen or PHP error after uploading
A file may not have uploaded completely. Try uploading again, or check your host's error log. Make sure config.php is still intact and has not been overwritten.
Admin → Upgrade shows no pending migrations but something seems broken
The migration list is based on filenames in the migrations/ folder compared to what has been recorded as applied. If the folder is empty or a file was renamed, the count may be wrong. Check that all files from the release package are present on your server.
A migration fails with "Access denied"
Your database user does not have enough privilege to run ALTER TABLE or CREATE INDEX. Use the manual method above — copy the SQL from the Upgrade page and run it via phpMyAdmin or SSH with a more privileged user.